in reply to Re: problem with a blocking recv function over socket
in thread problem with a blocking recv function over socket
i have already tried the second function in the following manner
# print "\nCalling recv()..."; my $select = IO::Select->new(); $select->add(LINK_HNDL); if($select->can_read(0)) { recv(LINK_HNDL, $temp, $size - length($data), $flags); #print "**$temp**\n"; } else { #print "No data on socket.\n"; }
instead of normal recieve call, but result is the application/server on board is getting slower, even during a healthy run. timeout is getting detected.
so what i want is, some way of setting recv so that it won't block when server is dead(not sure of this term,I mean switching off server(board on which it is running)abruptly).
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: problem with a blocking recv function over socket
by targetsmart (Curate) on May 12, 2009 at 10:07 UTC | |
by nav1729 (Initiate) on May 13, 2009 at 05:05 UTC |