scsh-users
[Top] [All Lists]

Re: socket-server

To: David Place <dplace@tiac.net>
Subject: Re: socket-server
From: Brian D. Carlstrom <bdc@martigny.ai.mit.edu>
Date: Fri, 1 Dec 95 09:55:03 -0800
Cc: SCSH List <scsh@martigny.ai.mit.edu>
Reply-to: "Brian D. Carlstrom" <bdc@ai.mit.edu>
>>> David Place writes:

     > Is there an easy way to implement socket-server
     > from these parts.  The scsh manual didn't enlighten me on this
     > topic.

Well the scsh manual has a chapter on networking that discusses out high
level socket routines. while bind-listen-accept-loop is poorly named, it
does make it easy to create a simple server.  included below an excerpt
from scsh/doc/cheat.txt. the old scheme 48 routines were somewhat
limited from what i remember, encouraging us to write a generic socket
implementation that would let you have full access to the system.

-bri

* Networking

** High Level Socket Routines 

*** clients
(socket-connect protocol-family/internet socket-type name port) -> socket
(socket-connect protocol-family/unix socket-type pathname) -> socket

*** server
(bind-listen-accept-loop protocol-family/internet proc port) -> does-not-return
(bind-listen-accept-loop protocol-family/unix proc pathname) -> does-not-return

proc is a procedure of two arguments: a socket and a socket-address


<Prev in Thread] Current Thread [Next in Thread>