Closed Bug 1368377 Opened 2 years ago Closed 2 years ago

Crash in java.lang.NullPointerException: Attempt to invoke interface method ''android.content.Context org.mozilla.gecko.ContextGetter.getContext()'' on a null object reference at org.mozilla.gecko.GeckoAppShell.getContext(GeckoAppShell.java)

Categories

(Firefox for Android :: General, defect, critical)

Unspecified
Android
defect
Not set
critical

Tracking

()

RESOLVED FIXED
Firefox 55
Tracking Status
firefox53 --- unaffected
firefox54 --- unaffected
firefox55 --- fixed

People

(Reporter: njn, Assigned: jchen)

References

Details

(Keywords: crash)

Crash Data

This bug was filed from the Socorro interface and is 
report bp-bc13f889-9027-499e-bd59-454640170528.
=============================================================

This is the #1 topcrash for Fennec 55, with 68 occurrences in the past 7 days.

The Java stack trace:

> java.lang.NullPointerException: Attempt to invoke interface method 'android.content.Context org.mozilla.gecko.ContextGetter.getContext()' on a null object reference
> 	at org.mozilla.gecko.GeckoAppShell.getContext(GeckoAppShell.java:1634)
> 	at org.mozilla.gecko.GlobalHistory.checkVisited(GlobalHistory.java:185)
> 	at org.mozilla.gecko.GlobalHistory.checkUriVisited(GlobalHistory.java:155)
> 	at org.mozilla.gecko.mozglue.GeckoLoader.nativeRun(Native Method)
> 	at org.mozilla.gecko.GeckoThread.run(GeckoThread.java:405)

Jim, any ideas?
Flags: needinfo?(nchen)
This seems to happen when the browser is not running, so is either during a background sync or check for updates.
From the stack I would say this looks like this happens during a background sync operation. To be sure, I have 2 tablets so I disabled sync on one and automatic updates on the other, so I should have the results of this experiment by tomorrow.
I did not have to wait long.  The one where I left the sync account enabled and turned off updates has crashed already.
Assignee: nobody → nchen
Status: NEW → ASSIGNED
Flags: needinfo?(nchen)
Depends on: 1369107
Technically the patches in bug 1369107 will fix this, but based on the current crash volume I'm going to land a quick fix for this particular bug first.
Pushed by nchen@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/3005c1464a2c
Use app context for GlobalHistory; r=me
https://hg.mozilla.org/mozilla-central/rev/3005c1464a2c
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
You need to log in before you can comment on or make changes to this bug.