diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2000-03-07 15:45:24 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2000-03-07 15:45:24 +0000 |
commit | 9f9f3e6e8548a596697778337110a423c384b6f3 (patch) | |
tree | 5dd4b290ef532cf5ecb058e1a92cd3435afeac8c /fs/binfmt_script.c | |
parent | d5c9a365ee7d2fded249aa5abfc5e89587583029 (diff) |
Merge with Linux 2.3.49.
Diffstat (limited to 'fs/binfmt_script.c')
-rw-r--r-- | fs/binfmt_script.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/binfmt_script.c b/fs/binfmt_script.c index be8695e2b..8c71ec4a9 100644 --- a/fs/binfmt_script.c +++ b/fs/binfmt_script.c @@ -11,6 +11,7 @@ #include <linux/malloc.h> #include <linux/binfmts.h> #include <linux/init.h> +#include <linux/smp_lock.h> static int do_load_script(struct linux_binprm *bprm,struct pt_regs *regs) { @@ -27,7 +28,9 @@ static int do_load_script(struct linux_binprm *bprm,struct pt_regs *regs) */ bprm->sh_bang++; + lock_kernel(); dput(bprm->dentry); + unlock_kernel(); bprm->dentry = NULL; bprm->buf[127] = '\0'; @@ -78,7 +81,9 @@ static int do_load_script(struct linux_binprm *bprm,struct pt_regs *regs) /* * OK, now restart the process with the interpreter's dentry. */ + lock_kernel(); dentry = open_namei(interp, 0, 0); + unlock_kernel(); if (IS_ERR(dentry)) return PTR_ERR(dentry); |