[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r37039 - libmicrohttpd/src/microhttpd
From: |
gnunet |
Subject: |
[GNUnet-SVN] r37039 - libmicrohttpd/src/microhttpd |
Date: |
Thu, 14 Apr 2016 12:20:24 +0200 |
Author: Karlson2k
Date: 2016-04-14 12:20:24 +0200 (Thu, 14 Apr 2016)
New Revision: 37039
Modified:
libmicrohttpd/src/microhttpd/daemon.c
Log:
Don't create daemon if failed to make daemon control pipe non-blocking
Modified: libmicrohttpd/src/microhttpd/daemon.c
===================================================================
--- libmicrohttpd/src/microhttpd/daemon.c 2016-04-14 10:20:22 UTC (rev
37038)
+++ libmicrohttpd/src/microhttpd/daemon.c 2016-04-14 10:20:24 UTC (rev
37039)
@@ -3782,7 +3782,18 @@
free (daemon);
return NULL;
}
- make_nonblocking (daemon, daemon->wpipe[0]);
+ if (MHD_NO == make_nonblocking (daemon, daemon->wpipe[0]))
+ {
+#ifdef HAVE_MESSAGES
+ MHD_DLOG (daemon,
+ "Failed to make control pipe non-blocking: %s\n",
+ MHD_strerror_ (errno));
+#endif
+ MHD_pipe_close_ (daemon->wpipe[0]);
+ MHD_pipe_close_ (daemon->wpipe[1]);
+ free (daemon);
+ return NULL;
+ }
make_nonblocking (daemon, daemon->wpipe[1]);
}
#ifndef MHD_WINSOCK_SOCKETS
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r37039 - libmicrohttpd/src/microhttpd,
gnunet <=