in reply to Re: Two way socket
in thread Two way socket

Well, actually, I was trying to send a file accross and I pasted the file code too.. my mistake, I only want to send data back and forth to the server from the socket client.. That's all!... It sounds to simple, but
$buf = <$s>; # Try to read a line print "$buf"; # Was there anyone on the other end? if (( defined $buf ) || ($buf =~ /\w/)) {

doesn't work, though it prints what the client sends in print $buf;, it does not go into the condition if (defined $buf) !!!!!