* [PATCH] fix load_elf_binary error path on unshare_files error
@ 2004-04-08 23:48 Chris Wright
0 siblings, 0 replies; 2+ messages in thread
From: Chris Wright @ 2004-04-08 23:48 UTC (permalink / raw)
To: Marcelo Tosatti; +Cc: linux-kernel, Kirill Korotaev
Make sure to return proper retval on unshare_files() error in
load_elf_binary. Patch against 2.4.26-rc2.
Error noted by Kirill Korotaev <kirillx@7ka.mipt.ru>.
===== fs/binfmt_elf.c 1.28 vs edited =====
--- 1.28/fs/binfmt_elf.c Thu Jan 29 15:08:42 2004
+++ edited/fs/binfmt_elf.c Thu Apr 8 15:12:15 2004
@@ -479,7 +479,8 @@
goto out_free_ph;
files = current->files; /* Refcounted so ok */
- if(unshare_files() < 0)
+ retval = unshare_files();
+ if (retval < 0)
goto out_free_ph;
if (files == current->files) {
put_files_struct(files);
^ permalink raw reply [flat|nested] 2+ messages in thread* [PATCH] fix load_elf_binary error path on unshare_files error
@ 2004-04-08 23:11 Chris Wright
0 siblings, 0 replies; 2+ messages in thread
From: Chris Wright @ 2004-04-08 23:11 UTC (permalink / raw)
To: akpm; +Cc: linux-kernel, Kirill Korotaev
Make sure to return proper retval on unshare_files() error in
load_elf_binary. Patch against 2.6.5.
Error noted by Kirill Korotaev <kirillx@7ka.mipt.ru>.
===== fs/binfmt_elf.c 1.69 vs edited =====
--- 1.69/fs/binfmt_elf.c Fri Mar 12 01:32:58 2004
+++ edited/fs/binfmt_elf.c Thu Apr 8 15:24:52 2004
@@ -509,7 +509,8 @@
goto out_free_ph;
files = current->files; /* Refcounted so ok */
- if(unshare_files() < 0)
+ retval = unshare_files();
+ if (retval < 0)
goto out_free_ph;
if (files == current->files) {
put_files_struct(files);
--
Linux Security Modules http://lsm.immunix.org http://lsm.bkbits.net
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2004-04-08 23:48 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-04-08 23:48 [PATCH] fix load_elf_binary error path on unshare_files error Chris Wright
-- strict thread matches above, loose matches on Subject: below --
2004-04-08 23:11 Chris Wright
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®