Closed Bug 1338670 Opened 5 years ago Closed 3 years ago

Crash in java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState at android.support.v4.app.FragmentManagerImpl.checkStateLoss(Unknown Source)

Categories

(Firefox for Android Graveyard :: General, defect, P5)

Unspecified
Android
defect

Tracking

(firefox51 affected, firefox52 wontfix, firefox53 affected, firefox54 affected)

RESOLVED WONTFIX
Tracking Status
firefox51 --- affected
firefox52 --- wontfix
firefox53 --- affected
firefox54 --- affected

People

(Reporter: ahunt, Unassigned)

References

Details

(Keywords: crash)

Crash Data

Another tab history fragment crash.

Bug 1120441 fixed one crash that could occur while trying to display the tab history fragment (that was ~12th on beta/release) - that bug had the same crash signature summary, we're now down to 34th on beta.

This bug was filed from the Socorro interface and is 
report bp-22ddf28d-ec9a-45dd-99ca-bf0fa2170210.
=============================================================

We have a few paths which result in crashes, all happening in the same location:

java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
	at android.support.v4.app.FragmentManagerImpl.checkStateLoss(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.popBackStackImmediate(Unknown Source)
	at org.mozilla.gecko.tabs.TabHistoryFragment.dismiss(TabHistoryFragment.java:142)
	at org.mozilla.gecko.tabs.TabHistoryFragment.onDestroy(TabHistoryFragment.java:109)
	at android.support.v4.app.Fragment.performDestroy(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.moveToState(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.moveToState(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.moveToState(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.dispatchDestroy(Unknown Source)
	at android.support.v4.app.FragmentController.dispatchDestroy(Unknown Source)
	at android.support.v4.app.FragmentActivity.onDestroy(Unknown Source)
	at android.support.v7.app.AppCompatActivity.onDestroy(Unknown Source)
	at org.mozilla.gecko.GeckoActivity.onDestroy(GeckoActivity.java:56)
	at org.mozilla.gecko.GeckoApp.onDestroy(GeckoApp.java:2287)
	at org.mozilla.gecko.BrowserApp.onDestroy(BrowserApp.java:1502)
	at android.app.Activity.performDestroy(Activity.java:7130)
	at android.app.Instrumentation.callActivityOnDestroy(Instrumentation.java:1171)
	at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:5095)
	at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:5140)
	at android.app.ActivityThread.access$1700(ActivityThread.java:229)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1880)
	at android.os.Handler.dispatchMessage(Handler.java:102)
	at android.os.Looper.loop(Looper.java:148)
	at android.app.ActivityThread.main(ActivityThread.java:7303)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)

-----------

java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
	at android.support.v4.app.FragmentManagerImpl.checkStateLoss(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.popBackStackImmediate(Unknown Source)
	at org.mozilla.gecko.tabs.TabHistoryFragment.dismiss(TabHistoryFragment.java:142)
	at org.mozilla.gecko.BrowserApp.onPrepareOptionsMenu(BrowserApp.java:3399)
	at org.mozilla.gecko.GeckoApp.invalidateOptionsMenu(GeckoApp.java:386)
	at org.mozilla.gecko.BrowserApp.onTabChanged(BrowserApp.java:400)
	at org.mozilla.gecko.Tabs$4.run(Tabs.java:676)
	at android.os.Handler.handleCallback(Handler.java:739)
	at android.os.Handler.dispatchMessage(Handler.java:95)
	at android.os.Looper.loop(Looper.java:148)
	at android.app.ActivityThread.main(ActivityThread.java:7325)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Then another onSaveInstanceState in an unrelated location (same signature though):

https://crash-stats.mozilla.com/report/index/2098abe7-ab0b-48d4-92d0-562ea2170209

java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
	at android.support.v4.app.FragmentManagerImpl.checkStateLoss(Unknown Source)
	at android.support.v4.app.FragmentManagerImpl.enqueueAction(Unknown Source)
	at android.support.v4.app.BackStackRecord.commitInternal(Unknown Source)
	at android.support.v4.app.BackStackRecord.commit(Unknown Source)
	at android.support.v4.app.DialogFragment.show(Unknown Source)
	at org.mozilla.gecko.widget.ExternalIntentDuringPrivateBrowsingPromptFragment.showDialogOrAndroidChooser(ExternalIntentDuringPrivateBrowsingPromptFragment.java:87)
	at org.mozilla.gecko.IntentHelper.openUriExternal(IntentHelper.java:147)
	at org.mozilla.gecko.GeckoApp.openUriExternal(GeckoApp.java:2600)
	at org.mozilla.gecko.GeckoAppShell.openUriExternal(GeckoAppShell.java:939)
	at org.mozilla.gecko.mozglue.GeckoLoader.nativeRun(Native Method)
	at org.mozilla.gecko.GeckoThread.run(GeckoThread.java:513)
This doesn't seem like a huge priority to fix, but the fix from Bug 1120441 is probably relevant here:
https://hg.mozilla.org/releases/mozilla-beta/rev/3b07081139ba
Too late for firefox 52, mass-wontfix.
See Also: → 1427076
Re-triaging per https://bugzilla.mozilla.org/show_bug.cgi?id=1473195

Needinfo :susheel if you think this bug should be re-triaged.
Priority: -- → P5
Closing because no crashes reported for 12 weeks.
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → WONTFIX
Closing because no crashes reported for 12 weeks.
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.