From 8b2effcc36f54561bf4d44b5297e4f022fc9f251 Mon Sep 17 00:00:00 2001 From: "Roger A. Light" Date: Tue, 8 Jul 2014 23:43:21 +0100 Subject: [PATCH] Don't check for POLLERR or POLLNVAL. Errors will be caught when trying to read anyway, and doing these checks here means that sockets may be closed prematurely. --- src/loop.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/loop.c b/src/loop.c index 5914e6f3..80963ff2 100644 --- a/src/loop.c +++ b/src/loop.c @@ -414,11 +414,6 @@ static void loop_handle_reads_writes(struct mosquitto_db *db, struct pollfd *pol continue; } } - - if(pollfds[context->pollfd_index].revents & (POLLERR | POLLNVAL)){ - do_disconnect(db, context); - continue; - } } }