Socket Communications

Tom Boutell boutell at freezer.it.udel.edu
Sat Apr 7 16:03:29 AEST 1990


I'm implementing multiuser stuff on a network of Suns. I acquired a file
called sock.c which contains some extremely useful code for that purpose
(thanks), but as far as I understand this code only covers the
server, and not the client, side of the relationship, unless conversa-
tional programs (ie, text adventures, etc) are the only desired result.

That is, when I run the included demo function, it waits for a player to
join. The only way I can see to join so far is to telnet to the appropriate
socket, which I can certainly do, producing a "Hello" message and endless
acknoledgements of the new player's id. As near as I can tell, this is in
keeping with the demo's purpose.

But what I can't do is do anything useful on the client end. How, instead
of using telnet, do I generate a link to that socket from a client program
and read and write the strings being communicated to it? Are socket numbers
constant within the network?  ... Et cetera. An answer to the basic question
of how to transmit and receive strings to a particular port from a remote
machine at low level, rather than by running telnet, would do me nicely.
Thanks, folks.

--
CRANBERRIES! ALBUQUERQUE! This is the start of the end of the beginning of
the middle of the last day of the first part of your life! NEWSPRINT GALORE!
Disclaimer: Datclaimer. Elvis is alive and doing my laundry. Turn down
your air guitar, I can't see the band! I lied, he's dead. Have a #$&$( day.



More information about the Comp.unix.questions mailing list