[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Listening to TCP port?
In <SMH.94Jun3191536@vapor.Franz.COM>, smh@Franz.COM (Steve Haflich) writes:
>In article <RICE.94Jun2144208@hpp-ss10-1.stanford.edu> rice@KSL.Stanford.EDU (James Rice) writes:
>
> From: rice@KSL.Stanford.EDU (James Rice)
>
> Hi, I'm in search of the necessary (hopefully) 3 lines of code under
> each of MCL and EXCL that will let me listen to a TCP port and, upon
> receipt of a connection, open a stream to it.
>
>For Franz Allegro see the source file ipc.cl in the lisp library.
>This code implements the both client and server tcp streams that are
>used for things like the emacs-lisp interface.
>...
I haven't take a look at this code yet but I'll do so. I have the same problem.
I do have a TCP/IP connection using stream sockets written in C that works
ok. My approach was to divide this code and make some specific functions
like "initialize a server", "read from the socket", "write to the socket"...
This way I would be able to use the foreign function interface while with the
old all-in-one code I would have Lisp hanging up until the end of the connection.
I've finished the first one(initialize), and although it works fine in C and estabilishes
the connection with the client, if I call it from Lisp I receive a "Bus Error"(signal 10)
message.
Any pointers?
Thanks in advance, Jose.
_____________________________________________________
Jose A. Rodrigues Nt. | Work: (408) 656-2786
NPGS | FAX : (408) 656-2458
2 UNIVERSITY CIR | Home: (408) 394-3837
MONTEREY CA 93943-2540 | rneto@nps.navy.mil
_____________________________________________________
== PHOENIX - The Naval Postgraduate School Autonomous Underwater Vehicle ==