]> git.ipfire.org Git - thirdparty/plymouth.git/commitdiff
utils: don't create pipes non-blocking
authorRay Strode <rstrode@redhat.com>
Tue, 11 Dec 2012 19:37:16 +0000 (14:37 -0500)
committerRay Strode <rstrode@redhat.com>
Tue, 11 Dec 2012 19:41:34 +0000 (14:41 -0500)
The daemonizing code depends on its pipe io being
blocking.  The other user of ply_open_unidirectional_pipe
will work with blocking or non blocking io.

This commit changes ply_open_unidirectional_pipe to create
blocking pipes.  This started causing failures with
commit 9ec69929 since it replaced broken code (passing
O_NONBLOCK to fcntl(fd, F_SETFD.. instead of F_SETFL)
with working code.

src/libply/ply-utils.c

index ed9219c277f7d6815264d0e506c9a9a6850312bd..833348523c5cb9579b9e555baba3a52ef0a5c4fa 100644 (file)
@@ -87,7 +87,7 @@ ply_open_unidirectional_pipe (int *sender_fd,
   assert (sender_fd != NULL);
   assert (receiver_fd != NULL);
 
-  if (pipe2 (pipe_fds, O_CLOEXEC | O_NONBLOCK) < 0)
+  if (pipe2 (pipe_fds, O_CLOEXEC) < 0)
     return false;
 
   *sender_fd = pipe_fds[1];