Initialize key structure to zero in charger
This is necessary because the key callback may not
be called before the states are checked.
Bug: 149107347
Test: Ensure charger does not reboot
Change-Id: I08d9e4b4046768eb0c0ca6171a2e5b7e5409d073
diff --git a/healthd/healthd_mode_charger.h b/healthd/healthd_mode_charger.h
index 370ca86..6e569ee 100644
--- a/healthd/healthd_mode_charger.h
+++ b/healthd/healthd_mode_charger.h
@@ -72,7 +72,7 @@
int64_t next_pwr_check_ = 0;
int64_t wait_batt_level_timestamp_ = 0;
- key_state keys_[KEY_MAX + 1];
+ key_state keys_[KEY_MAX + 1] = {};
animation batt_anim_;
GRSurface* surf_unknown_ = nullptr;