sh: Add more necessary INTOFF/INTON.
This commit is contained in:
parent
8237ba8ab3
commit
bc7f6652dd
@ -140,11 +140,13 @@ main(int argc, char *argv[])
|
||||
#endif
|
||||
rootpid = getpid();
|
||||
rootshell = 1;
|
||||
INTOFF;
|
||||
initvar();
|
||||
setstackmark(&smark);
|
||||
setstackmark(&smark2);
|
||||
procargs(argc, argv);
|
||||
pwd_init(iflag);
|
||||
INTON;
|
||||
if (iflag)
|
||||
chkmail(1);
|
||||
if (argv[0] && argv[0][0] == '-') {
|
||||
|
@ -475,7 +475,9 @@ getopts(char *optstr, char *optvar, char **optfirst, char ***optnext,
|
||||
}
|
||||
else {
|
||||
out1fmt("Illegal option -%c\n", c);
|
||||
INTOFF;
|
||||
(void) unsetvar("OPTARG");
|
||||
INTON;
|
||||
}
|
||||
c = '?';
|
||||
goto bad;
|
||||
@ -494,7 +496,9 @@ getopts(char *optstr, char *optvar, char **optfirst, char ***optnext,
|
||||
}
|
||||
else {
|
||||
out1fmt("No arg for -%c option\n", c);
|
||||
INTOFF;
|
||||
(void) unsetvar("OPTARG");
|
||||
INTON;
|
||||
c = '?';
|
||||
}
|
||||
goto bad;
|
||||
|
Loading…
Reference in New Issue
Block a user