This is an automatic generated email to let you know that the following patch were queued at the http://git.linuxtv.org/media_tree.git tree:
Subject: [media] v4l2-ioctl: fix W=1 warnings Author: Hans Verkuil <[email protected]> Date: Tue Oct 2 02:47:59 2012 -0300 Since the prt_names() macro is always called with an unsigned index the ((a) >= 0) condition is always true and gives a compiler warning when compiling with W=1. Rewrite the macro to avoid that warning, but cast the index to unsigned just in case it is ever called with a signed argument. Signed-off-by: Hans Verkuil <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]> drivers/media/v4l2-core/v4l2-ioctl.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) --- http://git.linuxtv.org/media_tree.git?a=commitdiff;h=d92462401dde1effa04a51d0a15000e6246d2a43 diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c index 11874c1..8f388ff 100644 --- a/drivers/media/v4l2-core/v4l2-ioctl.c +++ b/drivers/media/v4l2-core/v4l2-ioctl.c @@ -157,8 +157,7 @@ static const char *v4l2_memory_names[] = { [V4L2_MEMORY_OVERLAY] = "overlay", }; -#define prt_names(a, arr) ((((a) >= 0) && ((a) < ARRAY_SIZE(arr))) ? \ - arr[a] : "unknown") +#define prt_names(a, arr) (((unsigned)(a)) < ARRAY_SIZE(arr) ? arr[a] : "unknown") /* ------------------------------------------------------------------ */ /* debug help functions */ _______________________________________________ linuxtv-commits mailing list [email protected] http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits
