diff options
author | Tom Rix <[email protected]> | 2022-02-28 18:52:23 -0800 |
---|---|---|
committer | Jonathan Cameron <[email protected]> | 2022-04-04 09:19:01 +0100 |
commit | f50232193e61cf89a73130b5e843fef30763c428 (patch) | |
tree | 32dd70f076277f345c31424a5e46ac7e7774fb3a /lib/netdev-notifier-error-inject.c | |
parent | 460bfa65b0de72f4d8a808bc7cfb1cb591a95b18 (diff) |
iio: scd4x: check return of scd4x_write_and_fetch
Clang static analysis reports this problem
scd4x.c:474:10: warning: The left operand of '==' is a
garbage value
if (val == 0xff) {
~~~ ^
val is only set from a successful call to scd4x_write_and_fetch()
So check it's return.
Fixes: 49d22b695cbb ("drivers: iio: chemical: Add support for Sensirion SCD4x CO2 sensor")
Signed-off-by: Tom Rix <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Cc: <[email protected]>
Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'lib/netdev-notifier-error-inject.c')
0 files changed, 0 insertions, 0 deletions