I can't do math; fix bug introduced in 5a9761
This commit is contained in:
parent
215a9ce237
commit
549c62cc1c
1 changed files with 1 additions and 1 deletions
2
exec.c
2
exec.c
|
@ -61,7 +61,7 @@ exec(char *path, char **argv)
|
||||||
for(argc = 0; argv[argc]; argc++) {
|
for(argc = 0; argv[argc]; argc++) {
|
||||||
if(argc >= MAXARG)
|
if(argc >= MAXARG)
|
||||||
goto bad;
|
goto bad;
|
||||||
sp = (sp - strlen(argv[argc]) + 1) & ~3;
|
sp = (sp - (strlen(argv[argc]) + 1)) & ~3;
|
||||||
if(copyout(pgdir, sp, argv[argc], strlen(argv[argc]) + 1) < 0)
|
if(copyout(pgdir, sp, argv[argc], strlen(argv[argc]) + 1) < 0)
|
||||||
goto bad;
|
goto bad;
|
||||||
ustack[3+argc] = sp;
|
ustack[3+argc] = sp;
|
||||||
|
|
Loading…
Reference in a new issue