Re: inet_listen incompatibility.

Alan Cox (alan@lxorguk.ukuu.org.uk)
Mon, 27 Oct 1997 00:57:38 +0000 (GMT)


> However, the code for inet_listen() in net/ipv4/af_inet.c (kernel version
> 2.1.59) reads, starting at line 290:
>
> if (sock->state != SS_UNCONNECTED || sock->type != SOCK_STREAM)
> return(-EINVAL);
>
> Shouldn't this be:
>
> if (sock->state != SS_UNCONNECTED ||
> (sock->type != SOCK_STREAM && sock->type != SOCK_SEQPACKET))
> return(-EINVAL);
>
> according to the manpage?

No. There are no SOCK_SEQPACKET protocols as such in TCP/IP - examples
of sequenced packet protocols can be found elsewhere - X.25, AX.25 and
the Caldera SPX for example

(the fact linux allows a sock_seqpacket create in IP is the actual
bug I suspect ...)

Alan