hw5: preparing for submission

This commit is contained in:
Claudio Maggioni 2020-05-19 15:42:44 +02:00
parent 88a84fc310
commit 2df7f103a5
1 changed files with 6 additions and 0 deletions

View File

@ -59,6 +59,12 @@ process_execute (const char *file_name)
}
strlcpy(program_name, file_name, i+1);
struct file* f = filesys_open (program_name);
if (f == NULL) {
return TID_ERROR;
}
file_close(f);
/* Create a new thread to execute FILE_NAME. */
tid = thread_create (program_name, PRI_DEFAULT, start_process, fn_copy);
if (tid == TID_ERROR)