[Ecls-list] Proposed minor change to sockets.lisp

Zach Beane xach at xach.com
Sat Jul 30 10:47:29 UTC 2011


Matthew Mondor <mm_lists at pulsar-zone.net> writes:

> On Mon, 18 Jul 2011 13:15:01 -0400
> Matthew Mondor <mm_lists at pulsar-zone.net> wrote:
>
>> This minor patch adds a third value, the port number.  The SBCL
>> documentation on sb-bsd-sockets:socket-accept also only refers to two
>> values, but adding a third value should not hurt existing applications,
>> and seems to be the logical thing to do.  I did not check if the actual
>> SBCL implementation also now does it, but it's possible; it otherwise
>> would be good to file a bug report for it...
>
> At least according to SBCL's documentation string for SOCKET-ACCEPT, it
> also doesn't send the port number as a third value.

The documentation says this:

    Perform the accept(2) call, returning a newly-created connected
    socket and the peer address as multiple values

This is a little misleading, since the peer address is actually already
multiple values of the IP address and port. socket-accept on an inet
socket in SBCL will return three values, the second two of which make up
the peer address.

Zach






More information about the ecl-devel mailing list