From: Rickard Strandqvist
Date: Sat, 7 Jun 2014 13:26:37 +0200
> Logical conjunction always evaluates to false: minor < 2 && minor > 1
> I guess what you wanted is rather: minor > 2 || minor < 1
>
> This was partly found using a static code analysis program called cppcheck.
>
> Signed-off-by:
Hi
Thought about it, and now it becomes clearer.
But if someone decides to change the X or Y to a larger range than 1
and 2, it will not be correct ..?
Or, will it not happen?
But I'm no expert on this code :)
I just wanted to point out the logical error.
Best regards
Rickard Strandqvist
2014
On Sat, 2014-06-07 at 13:26 +0200, Rickard Strandqvist wrote:
> Logical conjunction always evaluates to false: minor < 2 && minor > 1
> I guess what you wanted is rather: minor > 2 || minor < 1
[]
> diff --git a/drivers/net/wimax/i2400m/control.c
> b/drivers/net/wimax/i2400m/control.c
[]
> @@ -10
Logical conjunction always evaluates to false: minor < 2 && minor > 1
I guess what you wanted is rather: minor > 2 || minor < 1
This was partly found using a static code analysis program called cppcheck.
Signed-off-by: Rickard Strandqvist
---
drivers/net/wimax/i2400m/control.c |2 +-
1 fil
4 matches
Mail list logo