aboutsummaryrefslogtreecommitdiffstats
path: root/lib/kernel/src
diff options
context:
space:
mode:
authorRaimo Niskanen <[email protected]>2013-07-16 15:14:50 +0200
committerRaimo Niskanen <[email protected]>2013-07-17 10:20:18 +0200
commit08ff3673e25fdd184ff92d45d4609cd423fd1e34 (patch)
tree75fa93a4ecb3431d33e74e39594f878c18cb077d /lib/kernel/src
parenta9f92f3d024feffe23303af141dc4b13c7c17aa5 (diff)
downloadotp-08ff3673e25fdd184ff92d45d4609cd423fd1e34.tar.gz
otp-08ff3673e25fdd184ff92d45d4609cd423fd1e34.tar.bz2
otp-08ff3673e25fdd184ff92d45d4609cd423fd1e34.zip
Implement netns for SCTP + bugfixes
Diffstat (limited to 'lib/kernel/src')
-rw-r--r--lib/kernel/src/inet.erl7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/kernel/src/inet.erl b/lib/kernel/src/inet.erl
index 0ee3234b05..e118382bfe 100644
--- a/lib/kernel/src/inet.erl
+++ b/lib/kernel/src/inet.erl
@@ -828,6 +828,13 @@ sctp_opt([Opt|Opts], Mod, R, As) ->
{sctp_module,_} -> sctp_opt (Opts, Mod, R, As); % Done with
inet -> sctp_opt (Opts, Mod, R, As); % Done with
inet6 -> sctp_opt (Opts, Mod, R, As); % Done with
+ {netns,NS} ->
+ case prim_inet:is_sockopt_val(netns, NS) of
+ true ->
+ sctp_opt(Opts, Mod, R#sctp_opts { fd = [Opt] }, As);
+ false ->
+ {error, badarg}
+ end;
{Name,Val} -> sctp_opt (Opts, Mod, R, As, Name, Val);
_ -> {error,badarg}
end;