Fix: remove bad check after epoll wait in consumer
authorDavid Goulet <dgoulet@efficios.com>
Thu, 29 Aug 2013 14:38:12 +0000 (10:38 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Thu, 29 Aug 2013 14:38:12 +0000 (10:38 -0400)
The returned nb_fd value is the number of FD ready for the requested I/O
so having and revents set to 0 is possible since not all fd are ready
thus making this check irrelevant and actually ressource consuming.

Signed-off-by: David Goulet <dgoulet@efficios.com>
src/common/consumer.c

index 7acb8560ca4e07bfdccc89518477dad6a8d79051..da24f81c50a3eac71108d007d3a3d4e5b4124583 100644 (file)
@@ -2197,11 +2197,6 @@ restart:
                        revents = LTTNG_POLL_GETEV(&events, i);
                        pollfd = LTTNG_POLL_GETFD(&events, i);
 
-                       /* Just don't waste time if no returned events for the fd */
-                       if (!revents) {
-                               continue;
-                       }
-
                        if (pollfd == lttng_pipe_get_readfd(ctx->consumer_metadata_pipe)) {
                                if (revents & (LPOLLERR | LPOLLHUP )) {
                                        DBG("Metadata thread pipe hung up");
This page took 0.027208 seconds and 4 git commands to generate.