V4L/DVB: media/IR: testing the wrong variable
authorDan Carpenter <error27@gmail.com>
Fri, 23 Jul 2010 10:08:26 +0000 (07:08 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 2 Aug 2010 19:43:00 +0000 (16:43 -0300)
There is a typo here.  We meant to test "rbuf" instead of "drv".  We
already tested "drv" earlier.

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/ir-lirc-codec.c

index ee1f2d443ab2b6950bbafe6eb350366cba1bf3c9..3ba482d96c4b17c388fbf4b75c364879cc51a6b3 100644 (file)
@@ -187,7 +187,7 @@ static int ir_lirc_register(struct input_dev *input_dev)
                return rc;
 
        rbuf = kzalloc(sizeof(struct lirc_buffer), GFP_KERNEL);
-       if (!drv)
+       if (!rbuf)
                goto rbuf_alloc_failed;
 
        rc = lirc_buffer_init(rbuf, sizeof(int), LIRCBUF_SIZE);