[Box Backup-commit] COMMIT r2817 - box/invisnet/perfhack1/lib/server

subversion at boxbackup.org subversion at boxbackup.org
Fri Dec 3 11:05:54 GMT 2010


Author: invisnet
Date: 2010-12-03 11:05:53 +0000 (Fri, 03 Dec 2010)
New Revision: 2817

Modified:
   box/invisnet/perfhack1/lib/server/SocketStreamTLS.cpp
Log:
Disable Naggle

Modified: box/invisnet/perfhack1/lib/server/SocketStreamTLS.cpp
===================================================================
--- box/invisnet/perfhack1/lib/server/SocketStreamTLS.cpp	2010-12-01 13:21:50 UTC (rev 2816)
+++ box/invisnet/perfhack1/lib/server/SocketStreamTLS.cpp	2010-12-03 11:05:53 UTC (rev 2817)
@@ -139,6 +139,11 @@
 		THROW_EXCEPTION(ServerException, TLSAllocationFailed)
 	}
 
+	// Naggle just gets in the way
+	int bOptVal = 1;
+	int bOptLen = sizeof(int);
+	setsockopt(socket, IPPROTO_TCP, TCP_NODELAY, (char*)&bOptVal, bOptLen);
+
 	// Make the socket non-blocking so timeouts on Read work
 
 #ifdef WIN32




More information about the Boxbackup-commit mailing list