commit | 80d344a4e1228e933ecb650d571a95aef1fed110 | [log] [tgz] |
---|---|---|
author | Treehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com> | Thu Dec 14 14:12:27 2023 +0000 |
committer | Android (Google) Code Review <android-gerrit@google.com> | Thu Dec 14 14:12:27 2023 +0000 |
tree | 2981f3d45840658209a36860d72c1604e1247be5 | |
parent | 859f225739693364a8b097b6fd28e0cc3cc127a7 [diff] | |
parent | 40d9abb773b77b43b7a8a63e394c792e90651c7d [diff] |
Merge "Fix Java crash problem" into main
diff --git a/src/com/android/settings/fuelgauge/batteryusage/SpinnerPreference.java b/src/com/android/settings/fuelgauge/batteryusage/SpinnerPreference.java index 0810158..2bcc7bf 100644 --- a/src/com/android/settings/fuelgauge/batteryusage/SpinnerPreference.java +++ b/src/com/android/settings/fuelgauge/batteryusage/SpinnerPreference.java
@@ -81,7 +81,8 @@ return; } if (!(state instanceof SavedState)) { - super.onRestoreInstanceState(state); + // To avoid the IllegalArgumentException, return the BaseSavedState.EMPTY_STATE. + super.onRestoreInstanceState(BaseSavedState.EMPTY_STATE); return; } SavedState savedState = (SavedState) state;