in reply to Re^3: Client-Server Programme hangs...
in thread Client-Server Programme hangs...
sub host_to_user { + my $nread ; my $inp ; $/ = CRLF ; while (<$socket>) { chomp; + my @data = split/-/, $_ ; print $_ , "\n"; print "The first value is $data[1]\n"; if ($data[1] eq 'THISISTHEEND') { $socket->close ; print " I have executed the close\n"; return 0 ; } } # + $socket->close ; #<- position 2 ###print " I have executed the close\n"; # return ; }
$ ./client Testing> Hello I have received your message[server]-THISISTHEEND The first value is THISISTHEEND I have executed the close Testing> So what ^C$ $
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Client-Server Programme hangs...
by Errto (Vicar) on Jan 05, 2005 at 03:33 UTC |