gecko-dev/dom/media/webspeech/synth
Kris Maglione a75561bd62 Bug 1412726: Clean up XPCOM singleton constructor refcount handling. r=froydnj
This is a follow-up to bug 1409249. There are a lot of places where our
factory singleton constructors either don't correctly handle their returned
references being released by the component manager, or do handle it, but in
ways that are not obvious.

This patch handles a few places where we can sometimes wind up with dangling
singleton pointers, adds some explanatory comments and sanity check
assertions, and replaces some uses of manual refcounting with StaticRefPtr and
ClearOnShutdown.

There are still some places where we may wind up with odd behavior if the
first QI for a getService call fails. In those cases, we wind up destroying
the first instance of a service that we create, and re-creating a new one
later.

MozReview-Commit-ID: ANYndvd7aZx

--HG--
extra : rebase_source : acfb0611a028fef6b9387eb5d1d9e285782fbc7c
2017-10-29 16:02:40 -07:00
..
cocoa Backed out 3 changesets (bug 1331696) for failing browser chrome on toolkit/components/narrate/test/browser_narrate.js r=backout on a CLOSED TREE 2017-12-07 00:25:35 +02:00
crashtests
ipc Backed out 3 changesets (bug 1331696) for failing browser chrome on toolkit/components/narrate/test/browser_narrate.js r=backout on a CLOSED TREE 2017-12-07 00:25:35 +02:00
speechd Bug 1412726: Clean up XPCOM singleton constructor refcount handling. r=froydnj 2017-10-29 16:02:40 -07:00
test Bug 1331696 - P2. make the speech synth mochitests pass. r=jya 2017-12-06 19:10:42 +01:00
windows Backed out 3 changesets (bug 1331696) for failing browser chrome on toolkit/components/narrate/test/browser_narrate.js r=backout on a CLOSED TREE 2017-12-07 00:25:35 +02:00
moz.build Bug 1394734 - Replace CONFIG['GNU_C*'] by CONFIG['CC_TYPE'] r=glandium 2017-12-07 22:09:15 +01:00
nsISpeechService.idl Backed out 3 changesets (bug 1331696) for failing browser chrome on toolkit/components/narrate/test/browser_narrate.js r=backout on a CLOSED TREE 2017-12-07 00:25:35 +02:00
nsISynthVoiceRegistry.idl
nsSpeechTask.cpp Bug 1331696 - P2. make the speech synth mochitests pass. r=jya 2017-12-06 19:10:42 +01:00
nsSpeechTask.h Backed out 3 changesets (bug 1331696) for failing browser chrome on toolkit/components/narrate/test/browser_narrate.js r=backout on a CLOSED TREE 2017-12-07 00:25:35 +02:00
nsSynthVoiceRegistry.cpp Bug 1412726: Clean up XPCOM singleton constructor refcount handling. r=froydnj 2017-10-29 16:02:40 -07:00
nsSynthVoiceRegistry.h Bug 1412726: Clean up XPCOM singleton constructor refcount handling. r=froydnj 2017-10-29 16:02:40 -07:00
SpeechSynthesis.cpp Bug 1331696 - P2. make the speech synth mochitests pass. r=jya 2017-12-06 19:10:42 +01:00
SpeechSynthesis.h
SpeechSynthesisUtterance.cpp Bug 1419597 - Part 18: Remove IsInnerWindow and IsOuterWindow methods, r=smaug 2017-11-23 13:12:13 -05:00
SpeechSynthesisUtterance.h Bug 1287006 - Adjust media/ code to not pass Maybe (or any class containing a Maybe member) by value, only by reference or pointer. r=jw_wang, r=rjesup 2017-02-13 09:07:40 -08:00
SpeechSynthesisVoice.cpp
SpeechSynthesisVoice.h