Commit 7ad151d0237b578bbf705b8f48e8f3538c2b0d44
1 parent
6e56c017
Exists in
master
add UNKNOWN to linux version
Showing
1 changed file
with
2 additions
and
0 deletions
Show diff stats
battery.c
@@ -43,6 +43,8 @@ void battery_state(int *nbats, int bat[], State state[]) { | @@ -43,6 +43,8 @@ void battery_state(int *nbats, int bat[], State state[]) { | ||
43 | state[i] = DISCHARGING; | 43 | state[i] = DISCHARGING; |
44 | else if (!strcmp(status, "Charging\n")) | 44 | else if (!strcmp(status, "Charging\n")) |
45 | state[i] = CHARGING; | 45 | state[i] = CHARGING; |
46 | + else | ||
47 | + state[i] = UNKNOWN; | ||
46 | 48 | ||
47 | // next | 49 | // next |
48 | i++; | 50 | i++; |