Skip to content
This repository has been archived by the owner on Apr 19, 2018. It is now read-only.

Probably fix intermittent irreproducible NPE #1067

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,10 @@ public void restoreActionViewStates(Bundle states) {
SparseArray<Parcelable> viewStates = states.getSparseParcelableArray(
getActionViewStatesKey());

if (viewStates == null) {
return; // NPE from View.restoreHierarchyState, dispatchRestoreInstanceState:6473.
}

final int itemCount = size();
for (int i = 0; i < itemCount; i++) {
final MenuItem item = getItem(i);
Expand Down