aboutsummaryrefslogtreecommitdiff
path: root/src/event_pipe.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-11-08 22:11:35 +0100
committerMax Kellermann <max@duempel.org>2009-11-08 22:11:35 +0100
commitf66edccffdc4a9276ae9dced69fa6fb74ee1f97e (patch)
tree3350b0852762cb393c12054e28c999532b4fd027 /src/event_pipe.c
parentb043ade456818a414c726c8525bb8ec63658edc8 (diff)
fd_util: added O_NONBLOCK functions
Changed the wrappers for pipe(), socket(), accept(). On WIN32, this does not work for pipe().
Diffstat (limited to 'src/event_pipe.c')
-rw-r--r--src/event_pipe.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/event_pipe.c b/src/event_pipe.c
index 17e11097..4b7e741f 100644
--- a/src/event_pipe.c
+++ b/src/event_pipe.c
@@ -18,7 +18,6 @@
*/
#include "event_pipe.h"
-#include "utils.h"
#include "fd_util.h"
#include <stdbool.h>
@@ -85,13 +84,9 @@ void event_pipe_init(void)
GIOChannel *channel;
int ret;
- ret = pipe_cloexec(event_pipe);
+ ret = pipe_cloexec_nonblock(event_pipe);
if (ret < 0)
g_error("Couldn't open pipe: %s", strerror(errno));
-#ifndef WIN32
- if (set_nonblocking(event_pipe[1]) < 0)
- g_error("Couldn't set non-blocking I/O: %s", strerror(errno));
-#endif
channel = g_io_channel_unix_new(event_pipe[0]);
event_pipe_source_id = g_io_add_watch(channel, G_IO_IN,