updates.
authorPekka Riikonen <priikone@silcnet.org>
Wed, 25 Jul 2001 15:47:54 +0000 (15:47 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Wed, 25 Jul 2001 15:47:54 +0000 (15:47 +0000)
CHANGES
lib/silcutil/unix/silcunixnet.c
lib/silcutil/win32/silcwin32net.c

diff --git a/CHANGES b/CHANGES
index ee878a57bf93e95c43801656979d5b3447de0080..c25fa149d2b057b5cfe3d73a73b8ec99308c8026 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,9 @@
+Wed Jul 25 18:43:54 EEST 2001  Pekka Riikonen <priikone@silcnet.org>
+
+       * Do not add TCP_NODELAY flag if the operating system
+         does not have it defined.  Affected files are
+         lib/silcutil/[unix/win32]/silc[unix/win32]net.c.
+
 Wed Jul 25 16:04:35 EEST 2001  Pekka Riikonen <priikone@silcnet.org>
 
        * Do not enable SILC_THREADS if the linking with libpthread
index de1b1e339f9e5db90238f24ca8462797fa194322..217b4bd04fac0540c0287f6ac5dd0090efed7a3b 100644 (file)
@@ -136,7 +136,9 @@ int silc_net_create_connection(int port, char *host)
   }
 
   /* Set appropriate options */
+#if defined(TCP_NODELAY)
   silc_net_set_socket_opt(sock, IPPROTO_TCP, TCP_NODELAY, 1);
+#endif
   silc_net_set_socket_opt(sock, SOL_SOCKET, SO_KEEPALIVE, 1);
 
   SILC_LOG_DEBUG(("Connection created"));
@@ -193,7 +195,9 @@ int silc_net_create_connection_async(int port, char *host)
   }
 
   /* Set appropriate options */
+#if defined(TCP_NODELAY)
   silc_net_set_socket_opt(sock, IPPROTO_TCP, TCP_NODELAY, 1);
+#endif
   silc_net_set_socket_opt(sock, SOL_SOCKET, SO_KEEPALIVE, 1);
 
   SILC_LOG_DEBUG(("Connection operation in progress"));
index 98b80a19bf3cfffe81f2d95a56c9bca1b1774a98..2e1338a1f7ecfbeaa9cdaffc0ead483d1597dd72 100644 (file)
@@ -139,7 +139,9 @@ int silc_net_create_connection(int port, char *host)
   }
 
   /* Set appropriate options */
+#if defined(TCP_NODELAY)
   silc_net_set_socket_opt(sock, IPPROTO_TCP, TCP_NODELAY, 1);
+#endif
   silc_net_set_socket_opt(sock, SOL_SOCKET, SO_KEEPALIVE, 1);
 
   SILC_LOG_DEBUG(("Connection created"));
@@ -196,7 +198,9 @@ int silc_net_create_connection_async(int port, char *host)
   silc_net_set_socket_nonblock(sock);
 
   /* Set appropriate options */
+#if defined(TCP_NODELAY)
   silc_net_set_socket_opt(sock, IPPROTO_TCP, TCP_NODELAY, 1);
+#endif
   silc_net_set_socket_opt(sock, SOL_SOCKET, SO_KEEPALIVE, 1);
 
   SILC_LOG_DEBUG(("Connection created"));