Question: A Linux thread that executes the following switch statement and takes the -1 case: switch( fork() ){ case -1: exit(0); case 0: execl(./new_prog, new_prog, NULL);
A Linux thread that executes the following switch statement and takes the -1 case:
switch( fork() ){ case -1: exit(0); case 0: execl("./new_prog", "new_prog", NULL); }a. creates a child and then terminates itself
b. leaves the switch statement and continues to execute its code
c. cannot create a child and thus terminates itself
d. creates a child process that can never become a zombie
Step by Step Solution
3.37 Rating (147 Votes )
There are 3 Steps involved in it
The detailed answer for the above question is provided below This code snippet is related to process ... View full answer
Get step-by-step solutions from verified subject matter experts
