s3: Make the write end of the echo responder pipe non-blocking
authorVolker Lendecke <vl@samba.org>
Wed, 6 Oct 2010 13:05:59 +0000 (15:05 +0200)
committerVolker Lendecke <vlendec@samba.org>
Wed, 6 Oct 2010 13:57:30 +0000 (13:57 +0000)
Without this, we can get a writable pipe end, but the writev call on the pipe
will block.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Oct  6 13:57:30 UTC 2010 on sn-devel-104

source3/smbd/process.c

index 8d36dd3c89ff1971672f6069267bea03aacb2b91..07fa67477d928fa2cb8be5e281585b8025adf500 100644 (file)
@@ -2839,6 +2839,7 @@ static bool fork_echo_handler(struct smbd_server_connection *sconn)
                NTSTATUS status;
 
                close(listener_pipe[0]);
+               set_blocking(listener_pipe[1], false);
 
                status = reinit_after_fork(sconn->msg_ctx,
                                           smbd_event_context(),