Q. When a child process terminates before the parent process closes, which of the following is true?

  • (A) The child process becomes an orphan
  • (B) The parent process disappears
  • (C) if the parent process does not support SIGCHLD, the child process becomes a zombie
  • (D) None of the above
πŸ’¬ Discuss
βœ… Correct Answer: (C) if the parent process does not support SIGCHLD, the child process becomes a zombie
Explanation: When a child process stops or terminates, SIGCHLD is sent to the parent process. The default response to the signal is to ignore it. The signal can be intercepted and the exit status of the child process can be obtained by immediately calling wait(2) and wait3(3C). This will remove zombie process entries as quickly as possible.
Explanation by: Mr. Dubey
When a child process stops or terminates, SIGCHLD is sent to the parent process. The default response to the signal is to ignore it. The signal can be intercepted and the exit status of the child process can be obtained by immediately calling wait(2) and wait3(3C). This will remove zombie process entries as quickly as possible.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
240
Total Visits
πŸ“½οΈ
4 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
84%
Success Rate