kern
diff src/proc.c @ 90:7ff2b4971216
started work on the filesystem
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Fri, 09 Dec 2011 13:44:15 +0200 |
parents | 8b21fe04ba2c |
children | 07fe6a614185 |
line diff
1.1 --- a/src/proc.c Thu Dec 08 18:19:35 2011 +0200 1.2 +++ b/src/proc.c Fri Dec 09 13:44:15 2011 +0200 1.3 @@ -165,6 +165,9 @@ 1.4 p = proc + pid; 1.5 parent = get_current_proc(); 1.6 1.7 + /* copy file table */ 1.8 + memcpy(p->files, parent->files, sizeof p->files); 1.9 + 1.10 /* allocate a kernel stack for the new process */ 1.11 if((p->kern_stack_pg = pgalloc(KERN_STACK_SIZE / PGSIZE, MEM_KERNEL)) == -1) { 1.12 return -EAGAIN;