Closed Bug 738976 Opened 12 years ago Closed 12 years ago

java.lang.RuntimeException: An error occured while executing doInBackground() at android.os.AsyncTask$3.done(AsyncTask.java) caused by: java.lang.NullPointerException at org.mozilla.gecko.db.LocalBrowserDB.updateFaviconForUrl(LocalBrowserDB.java:589)

Categories

(Firefox for Android Graveyard :: General, defect)

14 Branch
ARM
Android
defect
Not set
critical

Tracking

(firefox13 verified, firefox14 verified, blocking-fennec1.0 -)

VERIFIED FIXED
Firefox 14
Tracking Status
firefox13 --- verified
firefox14 --- verified
blocking-fennec1.0 --- -

People

(Reporter: scoobidiver, Assigned: mfinkle)

Details

(Keywords: crash, regression, Whiteboard: [native-crash])

Crash Data

Attachments

(2 files)

It first appeared in 14.0a1/20120323: bp-c7cf739f-bb12-411f-8e98-5cbab2120323.
The regression range might be:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=5c13fce74f83&tochange=ab2ff3b5611f

java.lang.RuntimeException: An error occured while executing doInBackground()
	at android.os.AsyncTask$3.done(AsyncTask.java:200)
	at java.util.concurrent.FutureTask$Sync.innerSetException(FutureTask.java:273)
	at java.util.concurrent.FutureTask.setException(FutureTask.java:124)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:307)
	at java.util.concurrent.FutureTask.run(FutureTask.java:137)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1068)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:561)
	at java.lang.Thread.run(Thread.java:1102)
Caused by: java.lang.NullPointerException
	at org.mozilla.gecko.db.LocalBrowserDB.updateFaviconForUrl(LocalBrowserDB.java:589)
	at org.mozilla.gecko.db.BrowserDB.updateFaviconForUrl(BrowserDB.java:186)
	at org.mozilla.gecko.Favicons$LoadFaviconTask.saveFaviconToDb(Favicons.java:265)
	at org.mozilla.gecko.Favicons$LoadFaviconTask.downloadFavicon(Favicons.java:327)
	at org.mozilla.gecko.Favicons$LoadFaviconTask.doInBackground(Favicons.java:383)
	at org.mozilla.gecko.Favicons$LoadFaviconTask.doInBackground(Favicons.java:226)
	at android.os.AsyncTask$2.call(AsyncTask.java:185)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)
	... 4 more

More reports at:
https://crash-stats.mozilla.com/report/list?signature=java.lang.RuntimeException%3A+An+error+occured+while+executing+doInBackground%28%29+at+android.os.AsyncTask%243.done%28AsyncTask.java%29
This is 104 crashes on trunk and about the same number on Aurora.
blocking-fennec1.0: --- → ?
(In reply to Kevin Brosnan [:kbrosnan] from comment #1)
> This is 104 crashes on trunk and about the same number on Aurora.
I see only one crash in 14.0a1 and no crashes in 13.0a2. You mixed it with bug 734624.
Status: NEW → RESOLVED
blocking-fennec1.0: ? → -
Closed: 12 years ago
Resolution: --- → FIXED
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
I see this with my own builds. Patch coming up.
Status: REOPENED → NEW
Attached patch patchSplinter Review
We do check higher in the callstack for a null drawable image, but in this case the drawable is fine. The getBitmap returns null though. This patch just bails if it does.

Fixes the crash I saw in my local builds. The favicon was a "jar:jar" that did not exist in the omnijar, so returning early is appropriate anyway.
Assignee: nobody → mark.finkle
Attachment #609619 - Flags: review?(blassey.bugs)
Attachment #609619 - Flags: review?(blassey.bugs) → review+
Attached file logcat
I can reproduce this.

Repro:
1) 3-26-2012 nightly fennec, Galaxy Nexus Android 4.0.2
2) open this URL in a new tab:  https://crash-stats.mozilla.com/report/index/bp-3ac9c353-2bc0-4322-afa7-930172120327
3) watch logcat, and verify the strictmode errors:

03-26 22:47:03.991: ERROR/StrictMode(29470): A resource was acquired at attached stack trace but never released. See java.io.Closeable for information on avoiding resource leaks.
03-26 22:47:03.991: ERROR/StrictMode(29470): java.lang.Throwable: Explicit termination method 'close' not called
03-26 22:47:03.991: ERROR/StrictMode(29470):     at dalvik.system.CloseGuard.open(CloseGuard.java:184)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at org.apache.harmony.xnet.provider.jsse.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:300)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at org.apache.harmony.xnet.provider.jsse.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:257)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpConnection.setupSecureSocket(HttpConnection.java:210)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpsURLConnectionImpl$HttpsEngine.makeSslConnection(HttpsURLConnectionImpl.java:477)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpsURLConnectionImpl$HttpsEngine.connect(HttpsURLConnectionImpl.java:432)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpEngine.sendSocketRequest(HttpEngine.java:282)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpEngine.sendRequest(HttpEngine.java:232)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:273)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpURLConnectionImpl.getHeaderField(HttpURLConnectionImpl.java:130)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.net.URLConnection.getHeaderFieldInt(URLConnection.java:552)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.net.URLConnection.getContentLength(URLConnection.java:320)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at libcore.net.http.HttpsURLConnectionImpl.getContentLength(HttpsURLConnectionImpl.java:190)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at org.mozilla.gecko.Favicons$LoadFaviconTask.downloadFavicon(Favicons.java:290)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at org.mozilla.gecko.Favicons$LoadFaviconTask.doInBackground(Favicons.java:369)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at org.mozilla.gecko.Favicons$LoadFaviconTask.doInBackground(Favicons.java:226)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at android.os.AsyncTask$2.call(AsyncTask.java:264)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.util.concurrent.FutureTask.run(FutureTask.java:137)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569)
03-26 22:47:03.991: ERROR/StrictMode(29470):     at java.lang.Thread.run(Thread.java:856)
https://hg.mozilla.org/mozilla-central/rev/27898323401e
Status: NEW → RESOLVED
Closed: 12 years ago12 years ago
Resolution: --- → FIXED
Looking trough the logs StrictMode errors are not present anymore on:
Nightly Fennec 16.0a1 (2012-06-11)
Aurora Fennec 15.0a2 (2012-06-11)
Device: HTC Desire Z
OS: Android 2.3.3
Status: RESOLVED → VERIFIED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: