From 16934ea87517d1b45419cadf2376a7da11a69b27 Mon Sep 17 00:00:00 2001 From: brain Date: Wed, 11 May 2005 23:47:09 +0000 Subject: added sendq stuff, see example config git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1362 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/users.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/users.cpp') 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(); -- cgit v1.2.3