summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-09-13 13:33:08 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-09-13 13:33:08 +0000
commit880de4edc72449ec92c1ed374e3f9ef1e5b290c3 (patch)
tree812c6334063cdb211502e76b0dd6c1cbd9acf066
parent6ce3e3bc0de4fe7faf2c7bed6e0b2d234b241f12 (diff)
downloadhercules-880de4edc72449ec92c1ed374e3f9ef1e5b290c3.tar.gz
hercules-880de4edc72449ec92c1ed374e3f9ef1e5b290c3.tar.bz2
hercules-880de4edc72449ec92c1ed374e3f9ef1e5b290c3.tar.xz
hercules-880de4edc72449ec92c1ed374e3f9ef1e5b290c3.zip
- Readded the setting TCP_NODELAY on socket.c to see if it fixes the walk-lag issue.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8731 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog-Trunk.txt3
-rw-r--r--src/common/socket.c8
2 files changed, 7 insertions, 4 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index 6517c3a69..2a10d0faf 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -3,6 +3,9 @@ Date Added
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
+2006/09/13
+ * Readded the setting TCP_NODELAY on socket.c to see if it fixes the
+ walk-lag issue. [Skotlex]
2006/09/12
* Modified the login SQL server so that case insensitive lookups use "where
name = BINARY 'name'" instead of "where BINARY name = 'name'", since this
diff --git a/src/common/socket.c b/src/common/socket.c
index e3ccb78a1..d13a3b4cb 100644
--- a/src/common/socket.c
+++ b/src/common/socket.c
@@ -86,7 +86,7 @@ void set_defaultparse(int (*defaultparse)(int))
void set_nonblocking(int fd, int yes) {
// I don't think we need this
// TCP_NODELAY BOOL Disables the Nagle algorithm for send coalescing.
- //setsockopt(sock,IPPROTO_TCP,TCP_NODELAY,(char *)&yes,sizeof yes);
+ setsockopt(fd,IPPROTO_TCP,TCP_NODELAY,(char *)&yes,sizeof yes);
// FIONBIO Use with a nonzero argp parameter to enable the nonblocking mode of socket s.
// The argp parameter is zero if nonblocking is to be disabled.
@@ -109,9 +109,9 @@ static void setsocketopts(int fd)
setsockopt(fd,SOL_SOCKET,SO_REUSEPORT,(char *)&yes,sizeof(yes));
#endif
#endif
-// setsockopt(sock,IPPROTO_TCP,TCP_NODELAY,(char *)&yes,sizeof(yes));
-// setsockopt(sock, SOL_SOCKET, SO_SNDBUF, (char *) &wfifo_size , sizeof(rfifo_size ));
-// setsockopt(sock, SOL_SOCKET, SO_RCVBUF, (char *) &rfifo_size , sizeof(rfifo_size ));
+ setsockopt(fd,IPPROTO_TCP,TCP_NODELAY,(char *)&yes,sizeof(yes));
+// setsockopt(fd, SOL_SOCKET, SO_SNDBUF, (char *) &wfifo_size , sizeof(rfifo_size ));
+// setsockopt(fd, SOL_SOCKET, SO_RCVBUF, (char *) &rfifo_size , sizeof(rfifo_size ));
#ifdef __WIN32
{ //set SO_LINGER option (from Freya)
//(http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/closesocket_2.asp)