Change to kill zombie procs after loop
This commit is contained in:
parent
243cf6a67c
commit
b80969f6af
@ -146,10 +146,9 @@ void processtree() {
|
||||
sprintf(num, "The value is %d\n", i);
|
||||
print_prompt(num);
|
||||
exit(0);
|
||||
} else {
|
||||
wait(NULL);
|
||||
}
|
||||
}
|
||||
while (wait(NULL) > 0);
|
||||
}
|
||||
|
||||
int main() {
|
||||
|
Loading…
Reference in New Issue
Block a user