X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fthreads%2Finit.c;h=f6a01dc67080688e44d3f45759c73745dcc75331;hb=15aa248a41556196803c75cb4f56ddad05f5d64e;hp=c17316aa59efec1951ad48eed5c8e4522a3e0381;hpb=5b670fb86ef37f5a81188e940e5fe1b04b5824af;p=pintos-anon diff --git a/src/threads/init.c b/src/threads/init.c index c17316a..f6a01dc 100644 --- a/src/threads/init.c +++ b/src/threads/init.c @@ -120,13 +120,8 @@ main (void) /* Run a user program. */ if (initial_program != NULL) { - tid_t tid; printf ("\nExecuting '%s':\n", initial_program); - tid = process_execute (initial_program); -#ifdef THREAD_JOIN_IMPLEMENTED - if (tid != TID_ERROR) - thread_join (tid); -#endif + process_wait (process_execute (initial_program)); } #else /* Run the compiled-in test function. */