Questions of 7 jul 02 (socketID)

Dar Scott dsc at swcp.com
Tue Jul 9 14:03:01 EDT 2002


On Tuesday, July 9, 2002, at 11:30 AM, peter.fink at tiscali.ch wrote:

> (what is also true: accept "assigns" a connection ID, but does not 
> deliver
> it to the script(s). the script(s) learn the connection ID at 
> callback time
> and in the form of a socket ID.)

Yes.  This is because you can get more than one connection--even at 
the same time.  The accept sets up the listen mechanism and that 
spins off callbacks.  The name "accept" might be confusing if you 
have used sockets in other environments; it does the work of 
"listen", but it also sets up a mechanism to "accept" connections 
and turn them into callbacks.

(If you only want one connection, you might want to write script to 
immediately close connections while one is active.)

I wish you well in your tcp/ip projects.

Dar Scott
(not THE Scott)







More information about the use-livecode mailing list