Re: [PATCH] usb: move assignment out of if condition

From: Greg KH
Date: Tue Jun 30 2015 - 11:10:12 EST


On Tue, Jun 30, 2015 at 09:02:22AM -0400, Kris Borer wrote:
> Fix four occurrences of the checkpatch.pl error:
>
> ERROR: do not use assignment in if condition

If you are going to do stuff like this, use Coccinelle so you are sure
you don't break the code.

Also always test your changes, if possible.

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/