From 53f280ed2ec0fdcac4e0e60f5d2566ae9f701a97 Mon Sep 17 00:00:00 2001 From: brain Date: Tue, 7 Mar 2006 17:32:55 +0000 Subject: Check for write errors in inspsocket (this is probably causing excessive cpu use when we have a large buffer to flush but a write error has occured (which we missed)) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3518 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/socket.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/socket.h') diff --git a/include/socket.h b/include/socket.h index 1c343f122..861d4be79 100644 --- a/include/socket.h +++ b/include/socket.h @@ -32,7 +32,7 @@ enum InspSocketState { I_DISCONNECTED, I_RESOLVING, I_CONNECTING, I_CONNECTED, I /** * Error types which a socket may exhibit */ -enum InspSocketError { I_ERR_TIMEOUT, I_ERR_SOCKET, I_ERR_CONNECT, I_ERR_BIND, I_ERR_RESOLVE }; +enum InspSocketError { I_ERR_TIMEOUT, I_ERR_SOCKET, I_ERR_CONNECT, I_ERR_BIND, I_ERR_RESOLVE, I_ERR_WRITE }; /** * InspSocket is an extendable socket class which modules @@ -143,7 +143,7 @@ private: /** Flushes the write buffer */ - void FlushWriteBuffer(); + bool FlushWriteBuffer(); void SetQueues(int nfd); -- cgit v1.2.3