staging: comedi: amplc_pci224: (!foo) preferred over (foo == NULL)
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Wed, 4 Mar 2015 19:15:30 +0000 (12:15 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 7 Mar 2015 00:01:28 +0000 (16:01 -0800)
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/amplc_pci224.c

index 88b8c0101c25d2508408a5e8a93598873cc2962e..8ac35f9fc69f843e4525cdca8e5e5219bf640422 100644 (file)
@@ -838,7 +838,7 @@ static int pci224_ao_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
        unsigned long flags;
 
        /* Cannot handle null/empty chanlist. */
-       if (cmd->chanlist == NULL || cmd->chanlist_len == 0)
+       if (!cmd->chanlist || cmd->chanlist_len == 0)
                return -EINVAL;
 
        /* Determine which channels are enabled and their load order.  */