diff options
author | Kanoj Sarcar <kanoj@engr.sgi.com> | 2000-03-15 02:36:21 +0000 |
---|---|---|
committer | Kanoj Sarcar <kanoj@engr.sgi.com> | 2000-03-15 02:36:21 +0000 |
commit | 24e4a693f41a00e1a497e250a3fcb65c6e62389c (patch) | |
tree | 30beb1f64abe0da1bfff42608ef941a2a0f4d47b /arch | |
parent | 44783319e929c332fc8baee64bb4d4144b10a16f (diff) |
Fix the default 32bit exec.
Diffstat (limited to 'arch')
-rw-r--r-- | arch/mips64/kernel/linux32.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/arch/mips64/kernel/linux32.c b/arch/mips64/kernel/linux32.c index 38ec7871b..b1b161348 100644 --- a/arch/mips64/kernel/linux32.c +++ b/arch/mips64/kernel/linux32.c @@ -1,4 +1,4 @@ -/* $Id: linux32.c,v 1.7 2000/03/06 23:24:34 ulfc Exp $ +/* $Id: linux32.c,v 1.8 2000/03/14 19:28:12 ulfc Exp $ * * Conversion between 32-bit and 64-bit native system calls. * @@ -386,6 +386,7 @@ sys32_execve(abi64_no_regargs, struct pt_regs regs) unsigned int envp = (unsigned int)regs.regs[6]; char **av, **ae; int na, ne, r, len; + char * filename; na = nargs(argv, NULL); ne = nargs(envp, NULL); @@ -414,9 +415,13 @@ sys32_execve(abi64_no_regargs, struct pt_regs regs) ae[ne] = (char *)0; (void)nargs(argv, av); (void)nargs(envp, ae); - regs.regs[5] = av; - regs.regs[6] = ae; - r = sys_execve(__dummy0,__dummy0,__dummy0,__dummy0,__dummy0,__dummy0,__dummy0,__dummy0, regs); + filename = getname((char *) (long)regs.regs[4]); + r = PTR_ERR(filename); + if (IS_ERR(filename)) + return(r); + + r = do_execve(filename, av, ae, ®s); + putname(filename); if (IS_ERR(r)) sys_munmap(av, len); return(r); |