more useful options | |
PerlMonks |
Re: In perl socket programming how to send a data from client and receive it from server and how to get number of clients processes and client ID?by hippo (Bishop) |
on May 01, 2019 at 07:44 UTC ( [id://1233220]=note: print w/replies, xml ) | Need Help?? |
how can I get the client ID and client count at server script? You already have the client count because you are storing a running count of the file descriptors in @clients and therefore the client count is scalar @clients (or $#clients + 1 if you prefer). As for the client ID it depends entirely what you mean by that. open my $fh, ">&=$fn" or warn $! and die; Can you explain why you warn $! and die here rather than just die $!?
In Section
Seekers of Perl Wisdom
|
|