about summary refs log tree commit homepage
diff options
context:
space:
mode:
-rw-r--r--nodelay.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/nodelay.c b/nodelay.c
index 265b0d6..afbb30e 100644
--- a/nodelay.c
+++ b/nodelay.c
@@ -55,7 +55,7 @@ int socket(int domain, int type, int protocol)
 
         if (fd >= 0 &&
             protocol == IPPROTO_TCP &&
-            type == SOCK_STREAM &&
+            (type & SOCK_STREAM) == SOCK_STREAM &&
             domain == PF_INET) {
                 int orig_errno = errno;
                 int optval = nodelay_value;