diff options
author | Jean Delvare <khali@linux-fr.org> | 2009-01-11 10:00:19 +0000 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2009-01-11 10:00:19 +0000 |
commit | e4d51acf7d77e2c8d9a5924deefd4e53657397ea (patch) | |
tree | 509575593fb7b5a6e83c46f8f16a65fd4896b5fa /lib/access.c | |
parent | 93aa7f3222456b81862478e883d493ddb670b81d (diff) | |
download | lm-sensors-git-e4d51acf7d77e2c8d9a5924deefd4e53657397ea.tar.gz |
Fix error propagation during expression evaluation.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@5581 7894878c-1315-0410-8ee3-d5d059ff63e0
Diffstat (limited to 'lib/access.c')
-rw-r--r-- | lib/access.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/access.c b/lib/access.c index 6fc24472..4e36df9a 100644 --- a/lib/access.c +++ b/lib/access.c @@ -437,10 +437,8 @@ int sensors_eval_expr(const sensors_chip_features *chip_features, if (!(subfeature = sensors_lookup_subfeature_name(chip_features, expr->data.var))) return -SENSORS_ERR_NO_ENTRY; - if (!(res = sensors_get_value(&chip_features->chip, - subfeature->number, result))) - return res; - return 0; + return sensors_get_value(&chip_features->chip, + subfeature->number, result); } if ((res = sensors_eval_expr(chip_features, expr->data.subexpr.sub1, val, &res1))) |