]> git.hungrycats.org Git - linux/commitdiff
[SPARC64]: Fix 32-bit execve out_mm error path.
authorDavid S. Miller <davem@nuts.ninka.net>
Tue, 20 Jan 2004 14:28:05 +0000 (06:28 -0800)
committerDavid S. Miller <davem@nuts.ninka.net>
Tue, 20 Jan 2004 14:28:05 +0000 (06:28 -0800)
Do not pass a NULL mm to mmdrop().

arch/sparc64/kernel/sys_sparc32.c

index 7e92f4f9456f66bfa353519657fc55e8f847ceb6..62c794535830565ffa21d602ca5420fcd7ca6d43 100644 (file)
@@ -2023,7 +2023,8 @@ out:
                security_bprm_free(&bprm);
 
 out_mm:
-       mmdrop(bprm.mm);
+       if (bprm.mm)
+               mmdrop(bprm.mm);
 
 out_file:
        if (bprm.file) {