Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The linux kernel allows to set the flag SOCK_CLOEXEC through the parameter type[1]. The implementation sets the flag through the parameter protocol and causes the call to socket()[2] to return -1 with EINVAL. This fixes the behaviour by OR-ing the flag SOCK_CLOEXEC to type instead of protocol. [1]: https://github.com/torvalds/linux/blob/v6.8/net/socket.c#L1655 [2]: https://man7.org/linux/man-pages/man2/socket.2.html
- Loading branch information