[poe-commits] poe/POE/Component/Server TCP.pm,1.37,1.38
Brought to you by:
rcaputo
From: <rc...@us...> - 2003-07-29 01:37:50
|
Update of /cvsroot/poe/poe/POE/Component/Server In directory sc8-pr-cvs1:/tmp/cvs-serv5337/POE/Component/Server Modified Files: TCP.pm Log Message: Silence the "connection reset by peer" errors, which indicate that a client has unceremoniously disconnected. To reiterate: These errors only occur in the default ClientError callback. Custom callbacks still receive notification of the errors and can handle them any way they see fit. Index: TCP.pm =================================================================== RCS file: /cvsroot/poe/poe/POE/Component/Server/TCP.pm,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -d -r1.37 -r1.38 *** TCP.pm 27 Jul 2003 18:29:54 -0000 1.37 --- TCP.pm 29 Jul 2003 00:25:28 -0000 1.38 *************** *** 10,14 **** use Carp qw(carp croak); use Socket qw(INADDR_ANY inet_ntoa); ! use POSIX qw(ECONNABORTED); # Explicit use to import the parameter constants. --- 10,14 ---- use Carp qw(carp croak); use Socket qw(INADDR_ANY inet_ntoa); ! use POSIX qw(ECONNABORTED ECONNRESET); # Explicit use to import the parameter constants. *************** *** 292,297 **** sub _default_client_error { my ($syscall, $errno, $error) = @_[ARG0..ARG2]; ! unless ($syscall eq "read" and $errno == 0) { ! $error = "Normal disconnection" unless $errno; warn( 'Client session ', $_[SESSION]->ID, --- 292,297 ---- sub _default_client_error { my ($syscall, $errno, $error) = @_[ARG0..ARG2]; ! unless ($syscall eq "read" and ($errno == 0 or $errno == ECONNRESET)) { ! $error = "(no error)" unless $errno; warn( 'Client session ', $_[SESSION]->ID, |