gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libmicrohttpd] 01/05: Examples: fixed blocking sockets on W32


From: gnunet
Subject: [libmicrohttpd] 01/05: Examples: fixed blocking sockets on W32
Date: Sun, 21 Nov 2021 13:44:28 +0100

This is an automated email from the git hooks/post-receive script.

karlson2k pushed a commit to branch master
in repository libmicrohttpd.

commit 0b9d6e9446ab3b9b121f9740d81d12bac2add09a
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Wed Nov 17 14:58:51 2021 +0300

    Examples: fixed blocking sockets on W32
    
    Sockets on W32 were non-blocking due to copy-paste errors.
---
 src/examples/upgrade_example.c            | 2 +-
 src/examples/websocket_threaded_example.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/examples/upgrade_example.c b/src/examples/upgrade_example.c
index b0cc869d..b63d8802 100644
--- a/src/examples/upgrade_example.c
+++ b/src/examples/upgrade_example.c
@@ -55,7 +55,7 @@ make_blocking (MHD_socket fd)
     if (-1 == fcntl (fd, F_SETFL, flags & ~O_NONBLOCK))
       abort ();
 #elif defined(MHD_WINSOCK_SOCKETS)
-  unsigned long flags = 1;
+  unsigned long flags = 0;
 
   ioctlsocket (fd, (int) FIONBIO, &flags);
 #endif /* MHD_WINSOCK_SOCKETS */
diff --git a/src/examples/websocket_threaded_example.c 
b/src/examples/websocket_threaded_example.c
index 1a2e2877..8680823f 100644
--- a/src/examples/websocket_threaded_example.c
+++ b/src/examples/websocket_threaded_example.c
@@ -524,7 +524,7 @@ make_blocking (MHD_socket fd)
     if (-1 == fcntl (fd, F_SETFL, flags & ~O_NONBLOCK))
       abort ();
 #elif defined(MHD_WINSOCK_SOCKETS)
-  unsigned long flags = 1;
+  unsigned long flags = 0;
 
   ioctlsocket (fd, (int) FIONBIO, &flags);
 #endif /* MHD_WINSOCK_SOCKETS */

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]