Commit 77c4aae
authored
Reorganize sockopts code and add several more socket options (#855)
Reorganize the sockopts code:
- Split the `sockopt` modules out of the syscalls.rs files into their own files
- Instead of duplicating all the documentation links for each socket option function, add a module-level documentation comment with all the links and just have the function documentation link to that.
- Reorganize the sockopt tests so that the socket and tcp options are tested on both ipv4 and ipv6 sockets.
- Adjust the bindings to reduce the amount of `as _` casting needed.
And, implement several more sockopt functions:
- Add `*_ifindex` variations of `IP_ADD_MEMBERSHIP` and `IP_DROP_MEMBERSHIP`
- Implement `IP_DROP_SOURCE_MEMBERSHIP`, `TCP_USER_TIMEOUT`, `IP_TOS`, `IPV6_RECVTCLASS`, `IP_RECVTOS`, `IP_ADD_SOURCE_MEMBERSHIP`, and `SO_OOBINLINE`.1 parent abd6686 commit 77c4aae
9 files changed
Lines changed: 2399 additions & 3089 deletions
File tree
- src
- backend
- libc/net
- linux_raw
- net
- net
- tests/net
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
| 8 | + | |
7 | 9 | | |
8 | 10 | | |
0 commit comments