Fix VFS panic "process has two calls" when closing a socket.
This commit is contained in:
parent
7d8d1b64b9
commit
81ce1c3df2
|
|
@ -12,7 +12,12 @@ close(int fd)
|
|||
|
||||
memset(&m, 0, sizeof(m));
|
||||
m.m_lc_vfs_close.fd = fd;
|
||||
m.m_lc_vfs_close.nblock = 0;
|
||||
|
||||
// When closing a socket VFS would output an error message:
|
||||
// "vfs(1): panic: process has two calls (105, 131)".
|
||||
// The fix is to make close non-blocking by default.
|
||||
// There's probably a better way to do this TODO.
|
||||
m.m_lc_vfs_close.nblock = 1;
|
||||
|
||||
return _syscall(VFS_PROC_NR, VFS_CLOSE, &m);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user