From: brain Date: Thu, 2 Nov 2006 21:56:35 +0000 (+0000) Subject: When we get an event on a userrec of EVENT_ERROR, and errornum is 0, send the error... X-Git-Tag: v2.0.23~6743 X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=139285820f9fa625713fb757ad868fb0642a0409;p=user%2Fhenk%2Fcode%2Finspircd.git When we get an event on a userrec of EVENT_ERROR, and errornum is 0, send the error message "EOF from client" rather than using strerror and getting: Quit (Unknown error: 0) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5633 e03df62e-2008-0410-955e-edbf42e46eb7 --- diff --git a/src/users.cpp b/src/users.cpp index 09c23acc0..17170fdb9 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -2043,7 +2043,7 @@ void userrec::HandleEvent(EventType et, int errornum) this->FlushWriteBuf(); break; case EVENT_ERROR: - this->SetWriteError(strerror(errornum)); + this->SetWriteError(errnum ? strerror(errornum) : "EOF from client"); break; } }