public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] kernel: fix mishandling of out of memory in poweroff
@ 2012-07-04 15:34 Alan Cox
  2012-07-10 20:15 ` Andrew Morton
  0 siblings, 1 reply; 6+ messages in thread
From: Alan Cox @ 2012-07-04 15:34 UTC (permalink / raw)
  To: linux-kernel, akpm

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");


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-07-11 11:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-04 15:34 [PATCH] kernel: fix mishandling of out of memory in poweroff Alan Cox
2012-07-10 20:15 ` 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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox