mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-27 17:18:53 +00:00
libc: sync bind sock control file before continuing with listen
Fix #2512
This commit is contained in:
parent
a79378ff19
commit
8207fb8d98
@ -502,6 +502,7 @@ extern "C" int socket_fs_bind(int libc_fd, sockaddr const *addr, socklen_t addrl
|
|||||||
int const len = strlen(addr_string.base());
|
int const len = strlen(addr_string.base());
|
||||||
int const n = write(context->bind_fd(), addr_string.base(), len);
|
int const n = write(context->bind_fd(), addr_string.base(), len);
|
||||||
if (n != len) return Errno(EACCES);
|
if (n != len) return Errno(EACCES);
|
||||||
|
fsync(context->bind_fd());
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user