develooper Front page | perl.beginners | Postings from January 2002

Access Transmitted Data On "Server" Side Of A TCP Socket

Thread Next
Hewlett Pickens
January 31, 2002 10:52
Access Transmitted Data On "Server" Side Of A TCP Socket
Message ID:
Using O'Reilly's "Learning Perl", have set up a "bare bones" socket
connection between two computers to send a small amount of data from the
"client" to the "server".  (For learning, not for the real world.)

The client sends "are you there" and the server responds with "I am here,
what do you want".

Each side prints the data it receives.

The client correctly displays the received:  "I am here ..."

The server displays junk for the data its received, meaning I haven't
correctly acquired it.

Code snippets from the server and client are in the text attachment.  I'd
appreciate it if someone could point out the error I'm making in the server



Hewlett M. Pickens
B I Moyle Associates, Inc.

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About