conditions: split the zero
commitf9691a61409ef14f7326e3c925c4b8b9b14fc6bc
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 6 Jul 2018 17:43:43 +0000 (6 20:43 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Fri, 6 Jul 2018 17:43:43 +0000 (6 20:43 +0300)
treecc86d5ae5eccedaa8671ac7ec0f494e7286c63ad
parentf19f13f1c0c1824ac80bf1cfe8be8bc246e367a2
conditions: split the zero

I have a check, which I should publish, which warns about if you do
"UINT_MAX + 1" because that's an integer overflow.  But it missed a bug
where we did "if (x == UINT_MAX + 1) ".  The problem is that the code
in smatch_conditions.c munges away comparisons to zero.

If it's not a EXPR_VALUE, let's split the expression like we normally
would.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
smatch_conditions.c