diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-05-11 23:47:09 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-05-11 23:47:09 +0000 |
commit | 16934ea87517d1b45419cadf2376a7da11a69b27 (patch) | |
tree | c61c95892022aa80f2a08adb8e7e3b69f88e68bc /src/users.cpp | |
parent | 70246812d3304b7c0ce81e7708c0fd98438ccd49 (diff) |
added sendq stuff, see example config
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1362 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/users.cpp')
-rw-r--r-- | src/users.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/users.cpp b/src/users.cpp index 0e676600e..5154b04cb 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -220,6 +220,14 @@ std::string userrec::GetBuffer() void userrec::AddWriteBuf(std::string data) { + if (this->GetWriteError() != "") + return; + if (sendq.length() + data.length() > this->sendqmax) + { + WriteOpers("*** User %s SendQ of %d exceeds connect class maximum of %d",this->nick,sendq.length() + data.length(),sendq.length()); + this->SetWriteError("SendQ exceeded"); + return; + } std::stringstream stream; stream << sendq << data; sendq = stream.str(); |