00001 /* Wait for a subprocess to finish, twice. 00002 The first call must wait in the usual way and return the exit code. 00003 The second wait call must return -1 immediately. */ 00004 00005 #include <syscall.h> 00006 #include "tests/lib.h" 00007 #include "tests/main.h" 00008 00009 void 00010 test_main (void) 00011 { 00012 pid_t child = exec ("child-simple"); 00013 msg ("wait(exec()) = %d", wait (child)); 00014 msg ("wait(exec()) = %d", wait (child)); 00015 }