Erlang/OTP Forums

Author Message

<  Erlang bugs mailing list  ~  gen_sctp:open fails on linux

Guest
Posted: Tue Apr 03, 2007 6:52 pm Reply with quote
Guest
I was testing out the SCTP support included in Erlang/OTP R11B-4 on a
linux 2.6.8 system. Calls to gen_sctp:open were failing. I narrowed
the problem down to an einval being returned while trying to set the
sndbuf socket option.

Looking at erts/emulator/drivers/common/inet_drv.c, it looks like it is
calling setsockopt(IPPROTO_SCTP, SO_SNDBUF, ...), which fails. I
believe that this should be calling setsockopt(SOL_SOCKET, SO_SNDBUF,
...) instead. Also, I think the same thing holds for SO_RCVBUF.

I made these changes in inet_drv.c, and the gen_sctp:open call succeeds
and I am able to use the SCTP socket.

-Jon
_______________________________________________
erlang-bugs mailing list
erlang-bugs@erlang.org
http://www.erlang.org/mailman/listinfo/erlang-bugs
Post recived from mailinglist
Guest
Posted: Wed Apr 04, 2007 8:51 am Reply with quote
Guest
Allright, very good. We will fix this at least to R11B-5.
I notice you do not need a patch yourself....


On Tue, Apr 03, 2007 at 02:51:22PM -0400, jrsantos@vanu.com wrote:
> I was testing out the SCTP support included in Erlang/OTP R11B-4 on a
> linux 2.6.8 system. Calls to gen_sctp:open were failing. I narrowed
> the problem down to an einval being returned while trying to set the
> sndbuf socket option.
>
> Looking at erts/emulator/drivers/common/inet_drv.c, it looks like it is
> calling setsockopt(IPPROTO_SCTP, SO_SNDBUF, ...), which fails. I
> believe that this should be calling setsockopt(SOL_SOCKET, SO_SNDBUF,
> ...) instead. Also, I think the same thing holds for SO_RCVBUF.
>
> I made these changes in inet_drv.c, and the gen_sctp:open call succeeds
> and I am able to use the SCTP socket.
>
> -Jon
> _______________________________________________
> erlang-bugs mailing list
> erlang-bugs@erlang.org
> http://www.erlang.org/mailman/listinfo/erlang-bugs

--

/ Raimo Niskanen, Erlang/OTP, Ericsson AB
_______________________________________________
erlang-bugs mailing list
erlang-bugs@erlang.org
http://www.erlang.org/mailman/listinfo/erlang-bugs
Post recived from mailinglist
Combo
Posted: Tue Apr 10, 2007 6:14 pm Reply with quote
Guest
Jessica Alba In *beep* Action Movie!
http://Jessica-Alba-In-*beep*-Action-Movie.info/WindowsMediaPlayer.php?movie=231891

Display posts from previous:  

All times are GMT
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum