tests/util/piglit-log.c: warning: comparison of unsigned enum \
expression < 0 is always false [-Wtautological-compare]
return opt < 0 || opt > PIGLIT_LOG_OPT_MAX;
~~~ ^ ~
Fix the warning by removing the dead comparison.
Signed-off-by: Chad Versace <[email protected]>
---
tests/util/piglit-log.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/util/piglit-log.c b/tests/util/piglit-log.c
index 99d13d3..ec5afcd 100644
--- a/tests/util/piglit-log.c
+++ b/tests/util/piglit-log.c
@@ -60,7 +60,7 @@ get_env_overrides(void)
static bool
is_opt_oob(enum piglit_log_opt opt)
{
- return opt < 0 || opt > PIGLIT_LOG_OPT_MAX;
+ return opt > PIGLIT_LOG_OPT_MAX;
}
intptr_t
--
2.0.0
_______________________________________________
Piglit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/piglit