Closed
Bug 1359935
Opened 9 years ago
Closed 8 years ago
Removing GC call in nsXREDirProvider::DoShutdown() leaks while running dom/presentation chrome mochitests
Categories
(Core :: DOM: Core & HTML, defect)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla55
People
(Reporter: mccr8, Assigned: mccr8)
References
Details
Attachments
(1 file)
No description provided.
| Assignee | ||
Comment 1•9 years ago
|
||
Four .jsms leak:
chrome://specialpowers/content/SpecialPowersObserver.jsm
file:///home/amccreight/mc/obj-dbg.noindex/dist/bin/components/multiprocessShims.js
resource://gre/modules/RemoteAddonsParent.jsm
resource://gre/modules/XPCOMUtils.jsm
| Assignee | ||
Comment 2•9 years ago
|
||
The leak occurs specifically with the test test_presentation_sender_startWithDevice.html
| Assignee | ||
Comment 3•9 years ago
|
||
This seems to be a bug with registerOriginalFactory in PresentationSessionChromeScript.js. This class sets up a number of mock factories for testing purposes, but it only unregisters those that are replacing an existing factory. Changing this so we unregister all of the factories (but only re-register when there was an existing factory) seems to fix the leak.
| Assignee | ||
Comment 4•9 years ago
|
||
My guess would be that this doesn't leak when the JS_GC is present because something very late in shutdown shakes out the factories, and then this final GC is somehow enough to cause the jsms to go away.
| Assignee | ||
Comment 5•9 years ago
|
||
Never mind, my patch does not actually fix anything. Need to investigate more.
| Assignee | ||
Comment 6•9 years ago
|
||
I think I have an actual fix now: for some reason, mockedSessionTransport.close() gets called after the special powers stuff has been torn down, and somehow calling sendAsyncMessage then causes a leak. I avoid this by not doing anything in close() if callback_ is null, which indicates that tearDown has been called already.
| Assignee | ||
Comment 7•9 years ago
|
||
| Comment hidden (mozreview-request) |
Comment 9•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8863059 [details]
Bug 1359935 - Don't call sendAsyncMessage in mockedSessionTransport.close() after tearDown.
https://reviewboard.mozilla.org/r/134896/#review138256
Looks good.
Thanks.
Attachment #8863059 -
Flags: review?(kechang) → review+
Comment 10•8 years ago
|
||
Pushed by amccreight@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/758e3a7da9bd
Don't call sendAsyncMessage in mockedSessionTransport.close() after tearDown. r=kershaw
Comment 11•8 years ago
|
||
| bugherder | ||
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox55:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
| Assignee | ||
Updated•8 years ago
|
status-firefox53:
--- → wontfix
status-firefox54:
--- → affected
status-firefox-esr45:
--- → wontfix
status-firefox-esr52:
--- → wontfix
| Assignee | ||
Comment 12•8 years ago
|
||
This is a test-only change that will be needed on beta if we are going to eventually uplift bug 833143 to beta to improve a shutdown hang.
Keywords: checkin-needed
Whiteboard: [checkin-needed Beta]
Comment 13•8 years ago
|
||
| bugherder uplift | ||
Updated•7 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•