Fixed a bug in bad_waitpid.c

The comments for this particular test suggest that the parent should
attempt waiting on itself. However, the code makes the parent wait
on its child. Fixed.
This commit is contained in:
Guru Prasad Srinivasa 2016-03-09 12:44:58 -05:00
parent eb7ad5609d
commit 44d53d9306

View File

@ -217,7 +217,7 @@ wait_parent(void)
report_survival(rv, errno, &result);
_exit(0);
}
rv = waitpid(childpid, &x, 0);
rv = waitpid(mypid, &x, 0);
report_beginsub("from parent:");
report_survival(rv, errno, &result);
return result;