Don't use getCurrentState() in BatteryStateMachine
getCurrentState() could throw ArrayIndexOutOfBoundsException when it's called during state transition. To avoid exception we can use the last connection state instead. Bug: 374013809 Flag: EXEMPT, no logic change Test: atest BatterServiceTest BatteryStateMachineTest Change-Id: I1cbbb4da6b16873b3f52d7d7c54c281413cde60d
Loading
Please register or sign in to comment