returns_negative_error_code: silence some false positives
commite469ccf873937cd1cf85b6d5d2b5df992cb531f1
authorDan Carpenter <dan.carpenter@linaro.org>
Fri, 19 May 2023 14:54:17 +0000 (19 17:54 +0300)
committerDan Carpenter <dan.carpenter@linaro.org>
Fri, 19 May 2023 14:54:17 +0000 (19 17:54 +0300)
tree460e159140bc5038e31c2043b560d2d390bbb825
parentb67adf444d50dc105abef3617256639fd116701d
returns_negative_error_code: silence some false positives

This is an issue with if (ret) vs if (ret < 0) {.  The function returns
s32min-(-1),1-s32max which holds negatives.  Then the caller does
if (ret < 0) and that means the else statement does not hold negative
error codes.

Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
check_returns_negative_error_code.c