generic-adc-battery: Pointer math issue in gab_probe()

psy->properties is an enum (32 bit type) so adding sizeof() puts us four
times further along than we intended.  It should be cast to a char pointer
before doing the math.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
This commit is contained in:
Dan Carpenter 2012-09-29 10:13:46 +03:00 • committed by Anton Vorontsov
commit a77d60aec7