s3c-adc-battery: Fix possible NULL pointer dereference
authorSyam Sidhardhan <syamsidhardh@gmail.com>
Sun, 24 Feb 2013 23:03:25 +0000 (04:33 +0530)
committerAnton Vorontsov <anton@enomsg.org>
Tue, 19 Mar 2013 02:43:03 +0000 (19:43 -0700)
commitc6cc9fc9d42ec82da2c770f0bef1488dc467f29c
tree792940a7c9afc196d69453b2b96b8c65f7dd3fe9
parent9239ebcffb9301eab75c638dcb702688884cc5d6
s3c-adc-battery: Fix possible NULL pointer dereference

Check for (bat == NULL) has to be done before accessing bat

Signed-off-by: Syam Sidhardhan <s.syam@samsung.com>
Signed-off-by: Anton Vorontsov <anton@enomsg.org>
drivers/power/s3c_adc_battery.c