From 0d31f9e8b16f85367045dbf543b39391ecc9d803 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Mon, 2 Jun 2014 16:18:10 +1000 Subject: [PATCH] test: compiler warning fixes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit misc.c: In function ‘create_simple_test_device’: misc.c:71:54: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] while ((type = va_arg(args, unsigned int)) != -1 && ^ misc.c:72:54: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] (code = va_arg(args, unsigned int)) != -1) { --- test/misc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/misc.c b/test/misc.c index f2088ca7..133bdb60 100644 --- a/test/misc.c +++ b/test/misc.c @@ -68,8 +68,8 @@ create_simple_test_device(const char *name, ...) va_start(args, name); - while ((type = va_arg(args, unsigned int)) != -1 && - (code = va_arg(args, unsigned int)) != -1) { + while ((type = va_arg(args, unsigned int)) != (unsigned int)-1 && + (code = va_arg(args, unsigned int)) != (unsigned int)-1) { const struct input_absinfo *a = NULL; if (type == EV_ABS) a = &abs;