Advertisement
Guest User

Untitled

a guest
Jan 20th, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.31 KB | None | 0 0
  1. static void
  2. close_files (struct thread *t)
  3. {
  4.   struct list_elem *cur;
  5.   while (!list_empty (&t->open_files))
  6.     {
  7.       cur = list_pop_back (&t->open_files);
  8.       struct open_file *file_data = list_entry (cur, struct open_file, elem);
  9.       file_close (file_data->file);
  10.       free (file_data);
  11.     }
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement