diff options
author | Micael Karlberg <[email protected]> | 2018-07-20 15:14:06 +0200 |
---|---|---|
committer | Micael Karlberg <[email protected]> | 2018-09-18 14:50:18 +0200 |
commit | 1c26ae984a79224ce64b40dbc7239bf9721bb096 (patch) | |
tree | bc01665931d21620dc152eeb402ad47f21bd0aac /lib/kernel/test/socket_server.erl | |
parent | 84f62ae80dd08874d0d5fbedc532605394e897c1 (diff) | |
download | otp-1c26ae984a79224ce64b40dbc7239bf9721bb096.tar.gz otp-1c26ae984a79224ce64b40dbc7239bf9721bb096.tar.bz2 otp-1c26ae984a79224ce64b40dbc7239bf9721bb096.zip |
[socket-nif] Add support for socket (level ip) option freebind
Added support for ip level socket option FREEBIND.
Note that there is an option available on FreeBSD called
IP_BINDANY, which seems to have similar properties (FREEBIND
is *not* available on FreeBSD). There are some restrictions
for this option though (which is not mentioned in the Linux
man page).
OTP-14831
Diffstat (limited to 'lib/kernel/test/socket_server.erl')
-rw-r--r-- | lib/kernel/test/socket_server.erl | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/kernel/test/socket_server.erl b/lib/kernel/test/socket_server.erl index 6aa26494f7..971ceb2093 100644 --- a/lib/kernel/test/socket_server.erl +++ b/lib/kernel/test/socket_server.erl @@ -604,6 +604,7 @@ handler_init(Manager, ID, Peek, Sock) -> SndTO = GSO(sndtimeo), Linger = GSO(linger), Timestamp = GSO(timestamp), + FreeBind = GIP(freebind), MTU = GIP(mtu), MTUDisc = GIP(mtu_discover), MALL = GIP(multicast_all), @@ -629,6 +630,7 @@ handler_init(Manager, ID, Peek, Sock) -> "~n (socket) SndTO: ~s" "~n (socket) Linger: ~s" "~n (socket) Timestamp: ~s" + "~n (ip) FreeBind: ~s" "~n (ip) MTU: ~s" "~n (ip) MTU Discovery: ~s" "~n (ip) Multicast ALL: ~s" @@ -642,7 +644,7 @@ handler_init(Manager, ID, Peek, Sock) -> RA, RP, B2D, OOBI, RcvBuf, RcvLW, RcvTO, SndBuf, SndLW, SndTO, Linger, Timestamp, - MTU, MTUDisc, MALL, MIF, MLoop, MTTL, + FreeBind, MTU, MTUDisc, MALL, MIF, MLoop, MTTL, NF, RecvTOS, RecvTTL]), handler_loop(#handler{peek = Peek, |