iio: light: apds9960: silence uninitialized variable warning
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 22 Apr 2016 10:04:14 +0000 (13:04 +0300)
committerJonathan Cameron <jic23@kernel.org>
Sat, 23 Apr 2016 21:18:09 +0000 (22:18 +0100)
commitf21122593d99c7e051891da1b148c771b7d56e07
tree01fd6b7cb33aee40d30c7da8d32af3051e292663
parenteb3798463f71afc77abd25b2f62708be06f7173b
iio: light: apds9960: silence uninitialized variable warning

It causes a static checker warning if we use "buf" on the failure path
so move that inside the if statement.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/light/apds9960.c