V4L/DVB: media/IR/imon: precendence issue: ! vs ==
authorDan Carpenter <error27@gmail.com>
Tue, 4 May 2010 11:37:33 +0000 (08:37 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Wed, 19 May 2010 15:59:03 +0000 (12:59 -0300)
The original condition is always false because ! has higher precedence
than == and neither 0 nor 1 is equal to IMON_DISPLAY_TYPE_VGA.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/IR/imon.c

index 27743eb0916da05d92c4abd1f5f3c6bfe4217fc6..9ca5e864d16f15ea9e6b6405dfd31b785137f8ed 100644 (file)
@@ -974,7 +974,7 @@ static void imon_touch_display_timeout(unsigned long data)
 {
        struct imon_context *ictx = (struct imon_context *)data;
 
-       if (!ictx->display_type == IMON_DISPLAY_TYPE_VGA)
+       if (ictx->display_type != IMON_DISPLAY_TYPE_VGA)
                return;
 
        input_report_abs(ictx->touch, ABS_X, ictx->touch_x);