From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: linux-kernel@vger.kernel.org, akpm@linux-foundation.org
Subject: [PATCH] kernel: fix mishandling of out of memory in poweroff
Date: Wed, 04 Jul 2012 16:34:51 +0100 [thread overview]
Message-ID: <20120704153443.4055.53130.stgit@bluebook> (raw)
From: Alan Cox <alan@linux.intel.com>
Coverity 703573
Signed-off-by: Alan Cox <alan@linux.intel.com>
---
kernel/sys.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/sys.c b/kernel/sys.c
index b04ae03..9271b7c 100644
--- a/kernel/sys.c
+++ b/kernel/sys.c
@@ -2212,13 +2212,13 @@ int orderly_poweroff(bool force)
ret = call_usermodehelper_fns(argv[0], argv, envp, UMH_NO_WAIT,
NULL, argv_cleanup, NULL);
-out:
if (likely(!ret))
return 0;
if (ret == -ENOMEM)
argv_free(argv);
+out:
if (force) {
printk(KERN_WARNING "Failed to start orderly shutdown: "
"forcing the issue\n");
next reply other threads:[~2012-07-04 14:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-04 15:34 Alan Cox [this message]
2012-07-10 20:15 ` [PATCH] kernel: fix mishandling of out of memory in poweroff Andrew Morton
2012-07-10 21:37 ` Scan Subscription
2012-07-11 9:30 ` Ozan Çağlayan
2012-07-11 9:35 ` richard -rw- weinberger
2012-07-11 11:22 ` Cong Wang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120704153443.4055.53130.stgit@bluebook \
--to=alan@lxorguk.ukuu.org.uk \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox