From bacc5b6c0abfd56bd1ac39d2a3a8cb0cb8b40a57 Mon Sep 17 00:00:00 2001 From: Chris Broekema <broekema@astron.nl> Date: Tue, 13 Feb 2007 08:25:53 +0000 Subject: [PATCH] BugID: 1011 Add recv and send buffer size to constructor --- LCS/Transport/include/Transport/TH_Socket.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/LCS/Transport/include/Transport/TH_Socket.h b/LCS/Transport/include/Transport/TH_Socket.h index 95af9a1574c..9d4db009b4a 100644 --- a/LCS/Transport/include/Transport/TH_Socket.h +++ b/LCS/Transport/include/Transport/TH_Socket.h @@ -49,14 +49,18 @@ public: const bool sync = true, int32 protocol = Socket::TCP, int32 backlog = 5, - const bool openSocketNow = true); + const bool openSocketNow = true, + const int recvBufferSize = -1, + const int serdBufferSize = -1); // Create a TH_Socket with a client socket. TH_Socket (const string& hostName, const string& service, const bool sync = true, int32 protocol = Socket::TCP, - const bool openSocketNow = true); + const bool openSocketNow = true, + const int recvBufferSize = -1, + const int sendBufferSize = -1); // Create a TH_Socket based on an existing data socket. TH_Socket (Socket* aDataSocket); @@ -127,6 +131,13 @@ private: // Administration for non-blocking receiving. In the recv-call // these fields are filled so that waitForRecv knows what to do. int16 itsLastCmd; + + /// when set, the Socket transport holder will adjust the + /// kernel level buffer size to the value provided when the + /// socket is initialised. + int itsRecvBufferSize; + int itsSendBufferSize; + }; inline bool TH_Socket::isClonable() const -- GitLab