summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/inspsocket.h2
-rw-r--r--src/inspsocket.cpp6
2 files changed, 4 insertions, 4 deletions
diff --git a/include/inspsocket.h b/include/inspsocket.h
index 9b24c2e85..a82f8bb82 100644
--- a/include/inspsocket.h
+++ b/include/inspsocket.h
@@ -157,7 +157,7 @@ class CoreExport BufferedSocket : public EventHandler
* more information without application-level queueing
* which was required in older software.
*/
- void SetQueues(int nfd);
+ void SetQueues();
/** When the socket has been marked as closing, this flag
* will be set to true, then the next time the socket is
diff --git a/src/inspsocket.cpp b/src/inspsocket.cpp
index fdb1dcf67..2d967d5e6 100644
--- a/src/inspsocket.cpp
+++ b/src/inspsocket.cpp
@@ -96,12 +96,12 @@ void BufferedSocket::WantWrite()
this->Instance->SE->WantWrite(this);
}
-void BufferedSocket::SetQueues(int nfd)
+void BufferedSocket::SetQueues()
{
// attempt to increase socket sendq and recvq as high as its possible
int sendbuf = 32768;
int recvbuf = 32768;
- if(setsockopt(nfd,SOL_SOCKET,SO_SNDBUF,(const char *)&sendbuf,sizeof(sendbuf)) || setsockopt(nfd,SOL_SOCKET,SO_RCVBUF,(const char *)&recvbuf,sizeof(sendbuf)))
+ if(setsockopt(this->fd,SOL_SOCKET,SO_SNDBUF,(const char *)&sendbuf,sizeof(sendbuf)) || setsockopt(this->fd,SOL_SOCKET,SO_RCVBUF,(const char *)&recvbuf,sizeof(sendbuf)))
{
//this->Instance->Log(DEFAULT, "Could not increase SO_SNDBUF/SO_RCVBUF for socket %u", GetFd());
; // do nothing. I'm a little sick of people trying to interpret this message as a result of why their incorrect setups don't work.
@@ -285,7 +285,7 @@ bool BufferedSocket::DoConnect(unsigned long maxtime)
this->state = I_ERROR;
return false;
}
- this->SetQueues(this->fd);
+ this->SetQueues();
}
Instance->Logs->Log("SOCKET", DEBUG,"BufferedSocket::DoConnect success");