summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-07-19 22:08:21 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-07-19 22:08:21 +0000
commita3caa8ccd9a48064e7483100ae2b355c52421529 (patch)
tree07db39fd406d50ea885545d7186ff9ddc1e01efc /src
parentfb3471e948092a5cbf9bea63272e190d5b7951f3 (diff)
Fix for bug #326, 'no error' quit can no longer theoretically occur because all errno == 0 are weeded out with a shorthand if() on calling userrec::SetWriteError, before, only one of three occurances
was. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7478 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/userprocess.cpp2
-rw-r--r--src/users.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/userprocess.cpp b/src/userprocess.cpp
index b27844fb6..3b9e717df 100644
--- a/src/userprocess.cpp
+++ b/src/userprocess.cpp
@@ -174,7 +174,7 @@ void InspIRCd::ProcessUser(userrec* cu)
if ((result == -1) && (errno != EAGAIN) && (errno != EINTR))
{
- cu->SetWriteError(strerror(errno));
+ cu->SetWriteError(errno ? strerror(errno) : "EOF from client");
return;
}
}
diff --git a/src/users.cpp b/src/users.cpp
index 7da7d6b09..8b9227083 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -741,7 +741,7 @@ void userrec::FlushWriteBuf()
{
/* Fatal error, set write error and bail
*/
- this->SetWriteError(strerror(errno));
+ this->SetWriteError(errno ? strerror(errno) : "EOF from client");
return;
}
}