Lines 120-125
Link Here
|
120 |
signal(SIGINT, SIG_IGN); |
120 |
signal(SIGINT, SIG_IGN); |
121 |
signal(SIGQUIT, SIG_IGN); |
121 |
signal(SIGQUIT, SIG_IGN); |
122 |
signal(SIGTERM, killed); |
122 |
signal(SIGTERM, killed); |
|
|
123 |
fclose(stdin); |
124 |
if (silent) { |
125 |
fclose(stdout); |
126 |
fclose(stderr); |
127 |
} |
123 |
if (waitpid(child, &status, 0) == -1) |
128 |
if (waitpid(child, &status, 0) == -1) |
124 |
err(EX_OSERR, "waitpid failed"); |
129 |
err(EX_OSERR, "waitpid failed"); |
125 |
return (WIFEXITED(status) ? WEXITSTATUS(status) : 1); |
130 |
return (WIFEXITED(status) ? WEXITSTATUS(status) : 1); |