mirror of
https://github.com/drasko/codezero.git
synced 2026-01-12 10:53:16 +01:00
open file descriptor references to vm files weren't properly initialised.
This fixes the issue. sys_read/write yet to be inspected.
This commit is contained in:
@@ -94,10 +94,14 @@ int vfs_receive_sys_open(l4id_t sender, l4id_t opener, int fd,
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Initialise and add it to global list */
|
||||
/* Initialise and add a reference to it from the task */
|
||||
vm_file_to_vnum(vmfile) = vnum;
|
||||
vmfile->length = length;
|
||||
vmfile->vm_obj.pager = &file_pager;
|
||||
t->fd[fd].vmfile = vmfile;
|
||||
vmfile->vm_obj.refcnt++;
|
||||
|
||||
/* Add to global list */
|
||||
list_add(&vmfile->vm_obj.list, &vm_file_list);
|
||||
|
||||
l4_ipc_return(0);
|
||||
|
||||
Reference in New Issue
Block a user