Merge branch 'linus' into x86/amd-iommu
[pandora-kernel.git] / fs / binfmt_misc.c
index dbf0ac0..7191306 100644 (file)
@@ -115,6 +115,12 @@ static int load_misc_binary(struct linux_binprm *bprm, struct pt_regs *regs)
        if (!enabled)
                goto _ret;
 
+       retval = -ENOEXEC;
+       if (bprm->misc_bang)
+               goto _ret;
+
+       bprm->misc_bang = 1;
+
        /* to keep locking time low, we copy the interpreter string */
        read_lock(&entries_lock);
        fmt = check_file(bprm);