diff options
Diffstat (limited to 'src/common')
-rw-r--r-- | src/common/socket.c | 8 |
1 files changed, 4 insertions, 4 deletions
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)
|