From 12d1308838f30af13dc917323a4bcc70b5d97e81 Mon Sep 17 00:00:00 2001 From: David Goulet Date: Tue, 4 Jun 2013 15:56:43 -0400 Subject: [PATCH] Fix: remove nonblock flag of sessiond socket in consumer There is no need for non blocking socket. Furthermore, we have observed unstable behaviors with a non blocking side (consumer) and a blocking side (sessiond). Acked-by: Mathieu Desnoyers Signed-off-by: David Goulet --- src/common/consumer.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/src/common/consumer.c b/src/common/consumer.c index feec3562d..45eede109 100644 --- a/src/common/consumer.c +++ b/src/common/consumer.c @@ -2873,12 +2873,6 @@ void *consumer_thread_sessiond_poll(void *data) goto end; } - ret = fcntl(client_socket, F_SETFL, O_NONBLOCK); - if (ret < 0) { - PERROR("fcntl O_NONBLOCK"); - goto end; - } - /* prepare the FDs to poll : to client socket and the should_quit pipe */ consumer_sockpoll[0].fd = ctx->consumer_should_quit[0]; consumer_sockpoll[0].events = POLLIN | POLLPRI; @@ -2896,11 +2890,6 @@ void *consumer_thread_sessiond_poll(void *data) WARN("On accept"); goto end; } - ret = fcntl(sock, F_SETFL, O_NONBLOCK); - if (ret < 0) { - PERROR("fcntl O_NONBLOCK"); - goto end; - } /* * Setup metadata socket which is the second socket connection on the -- 2.34.1