[Ecls-list] About sockets - maybe last iteration?
Tobias C. Rittweiler
tcr at freebits.de
Thu Feb 18 13:41:25 UTC 2010
Juan Jose Garcia-Ripoll
<juanjose.garciaripoll at googlemail.com> writes:
> I have revisited the SB-SOCKETS code and implemented the following changes.
>
> 1- The composite streams now have an internal flag indicating that its
> components should be automatically closed.
>
> 2- When requesting input/output streams, the function
> SOCKET-MAKE-STREAM creates a two-way stream that automatically closes
> its components.
>
> 3- SOCKET-MAKE-STREAM has a total of four keyword arguments
> :BUFFERING, :EXTERNAL-FORMAT, :INPUT and :OUTPUT that behave just like
> SBCL's
>
> 4- Use of :INPUT or :OUTPUT is needed now.
>
> With these changes Slime runs fine in my system. Please have a look at
> your own code and tests programs to see whether this solution fits
> your needs and is working properly.
>
> Juanjo
> (require :sb-bsd-sockets)
;;; Loading #P"/home/tcr/software/ecl-git/lib/ecl-10.2.1/sb-bsd-sockets.fas"
;;; Loading #P"/home/tcr/software/ecl-git/lib/ecl-10.2.1/sockets.fas"
("SB-BSD-SOCKETS" "SOCKETS")
> (sb-bsd-sockets:socket-make-stream
(make-instance 'sb-bsd-sockets:inet-socket
:type :stream
:protocol :tcp)
:output t
:input t
:external-format :utf-8)
Cannot change external format of stream #<two-way stream 08a55910>
Available restarts:
1. (RESTART-TOPLEVEL) Go back to Top-Level REPL.
Broken at SB-BSD-SOCKETS:SOCKET-MAKE-STREAM. In: #<process SI:TOP-LEVEL 08a40fc0>.
More information about the ecl-devel
mailing list