Input: lm8323 - missing error check in lm8323_set_disable()

The missing error handling here is not especially harmful but static
checkers complain that "i" can be used uninitialized.

Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
This commit is contained in:
Dan Carpenter 2014-12-02 21:55:53 -08:00 • committed by Dmitry Torokhov
commit 3b5005e920

View file

@ -616,6 +616,8 @@ static ssize_t lm8323_set_disable(struct device *dev,
unsigned int i;
ret = kstrtouint(buf, 10, &i);
if (ret)
return ret;
mutex_lock(&lm->lock);
lm->kp_enabled = !i;