diff options
author | Ethan Chen <intervigil@gmail.com> | 2016-07-12 18:38:00 -0700 |
---|---|---|
committer | Ethan Chen <intervigil@gmail.com> | 2016-07-12 18:38:00 -0700 |
commit | 3ecf3c46481805936277f80dfd76160f664656d7 (patch) | |
tree | 3f05e12479ac74e8abaf7492d434c7ab073cdbd6 | |
parent | 2879c69f2b39ec7a0c1fbaa54bb2bdcf60fd5b6a (diff) | |
download | android_hardware_samsung-3ecf3c46481805936277f80dfd76160f664656d7.tar.gz android_hardware_samsung-3ecf3c46481805936277f80dfd76160f664656d7.tar.bz2 android_hardware_samsung-3ecf3c46481805936277f80dfd76160f664656d7.zip |
power: Fix compilation failure
Change-Id: Ib0923ba5c0976e2d00e6f190b370936a14a9b6df
-rw-r--r-- | power/power.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/power/power.c b/power/power.c index f54c72f..3cf9cc2 100644 --- a/power/power.c +++ b/power/power.c @@ -125,7 +125,7 @@ static void sysfs_write(const char *path, char *s) } static unsigned int read_panel_brightness() { - unsigned int ret = 0; + unsigned int i, ret = 0; int read_status; // brightness can range from 0 to 255, so max. 3 chars + '\0' char panel_brightness[4]; @@ -136,7 +136,7 @@ static unsigned int read_panel_brightness() { return -1; } - for (unsigned int i = 0; i < (sizeof(panel_brightness) / sizeof(panel_brightness[0])); i++) { + for (i = 0; i < (sizeof(panel_brightness) / sizeof(panel_brightness[0])); i++) { if (isdigit(panel_brightness[i])) { ret += (panel_brightness[i] - '0'); } |