What is the difference between wait(null) and wait(&status) in c system programming?
wait(null)
wait(&status)
And what is the content of the pointer status ? >
wait(NULL) will only wait until the child process is completed. But, wait(&status) will return the process id of the child process that is terminated.
wait(NULL)
pid = wait(&status); // the information is returned