Closed Bug 1163410 Opened 9 years ago Closed 9 years ago

Intermittent serviceworkers/test_request_context.html | application crashed [@ JS::Rooted<JS::Value>::Rooted(JSContext*)] or [@ ServiceWorkerClientPostMessageRunnable::DispatchDOMEvent]

Categories

(Core :: DOM: Service Workers, defect)

ARM
Android
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla42
Tracking Status
firefox40 --- disabled
firefox41 --- disabled
firefox42 --- fixed
firefox-esr31 --- unaffected
firefox-esr38 --- unaffected
b2g-master --- fixed

People

(Reporter: philor, Assigned: ehsan.akhgari)

References

Details

(Keywords: intermittent-failure)

Attachments

(2 files, 1 obsolete file)

      No description provided.
Any ideas, Nikhil?
Flags: needinfo?(nsm.nikhil)
catalin pointed out that i should try with Bug 1158728
Flags: needinfo?(nsm.nikhil)
I guess using inner window didn't work.
Attached file MozReview Request: bz://1163410/nsm (obsolete) —
/r/9471 - Bug 1163410 - Hold refptr to window. r=catalinb

Pull down this commit:

hg pull -r 23f41ae122aa2a2b7cd16d042f4a945f93483565 https://reviewboard-hg.mozilla.org/gecko/
Attachment #8611361 - Flags: review?(catalin.badea392)
Comment on attachment 8611361 [details]
MozReview Request: bz://1163410/nsm

https://reviewboard.mozilla.org/r/9469/#review8221

Aren't all window objects owned by the main thread? How can the window be deref-ed between getting the reference and dispatching the event?
Attachment #8611361 - Flags: review?(catalin.badea392) → review+
https://reviewboard.mozilla.org/r/9469/#review8261

I'm going to hazard a guess that either AutoJSAPI or some other caller can cause a GC, leading to the window going away.
:nsm -- Are you still investigating? Should the patch from comment 88 be checked in?
Flags: needinfo?(nsm.nikhil)
Its on my radar but I'm not working on it right now. The patch from comment 88 didn't help.
Flags: needinfo?(nsm.nikhil)
Summary: Intermittent serviceworkers/test_request_context.html | application crashed [@ JS::Rooted<JS::Value>::Rooted(JSContext*)] → Intermittent serviceworkers/test_request_context.html | application crashed [@ JS::Rooted<JS::Value>::Rooted(JSContext*)] or [@ ServiceWorkerClientPostMessageRunnable::DispatchDOMEvent]
I think it's time to disable this test if we can't make any traction on fixing it.
Flags: needinfo?(nsm.nikhil)
I won't be able to work on this until Whistler.
Flags: needinfo?(nsm.nikhil)
Looking at the crashes here more closely, the JSContext pointer is null, which is caused since we don't check whether JSAPI has been properly initialized.
Assignee: nobody → ehsan
Status: NEW → ASSIGNED
Attachment #8627216 - Flags: review?(nsm.nikhil)
Whiteboard: [test disabled on Android][leave open]
Blocks: 1148935
Comment on attachment 8627216 [details] [diff] [review]
Ensure that JSAPI is initialized

Review of attachment 8627216 [details] [diff] [review]:
-----------------------------------------------------------------

of course!
Attachment #8627216 - Flags: review?(nsm.nikhil) → review+
I think the code fix here is still valuable to have, but clearly the problems with test have not all been solved yet.  I will investigate.
Flags: needinfo?(ehsan)
https://hg.mozilla.org/mozilla-central/rev/ef32543a45b0
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla42
You need to log in before you can comment on or make changes to this bug.