Fix: macro compares unsigned to 0 (no effect)
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Tue, 17 May 2016 13:01:51 +0000 (09:01 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 17 May 2016 19:36:05 +0000 (15:36 -0400)
Found by Coverity:

CID 1262117 (#1 of 1): Macro compares unsigned to 0
(NO_EFFECT)unsigned_compare: This greater-than-or-equal-to-zero
comparison of an unsigned value is always true. events->nb_fd >= 0U.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/common/compat/compat-epoll.c

index 58f50cc94dd83e33448ca31ebdb2fd2594fee88a..6259fd3895e46b9b27826944c1b7574b72b72ff3 100644 (file)
@@ -208,7 +208,6 @@ int compat_epoll_wait(struct lttng_poll_event *events, int timeout)
                ERR("Wrong arguments in compat_epoll_wait");
                goto error;
        }
-       assert(events->nb_fd >= 0);
 
        if (events->nb_fd == 0) {
                errno = EINVAL;
This page took 0.026523 seconds and 5 git commands to generate.