Closed Bug 1226015 Opened 4 years ago Closed 4 years ago

[SpeechSynthesis] Calling pause/cancel after a short lived utterance causes a race condition in e10s

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla45
Tracking Status
e10s + ---
firefox45 --- fixed

People

(Reporter: eeejay, Assigned: eeejay)

References

Details

Attachments

(1 file)

An utterance could be short lived if it fails immediately after speak, or if it an empty string that completes "speaking" instantly.

Consider the following js:
speechSynthesis.speak(new SpeechSynthesisUtterance());
speechSynthesis.cancel();

If called from a child content process the protocol will be created and then destroyed before the cancel is sent to the parent process.
I tried and failed to understand where we're crashing and why the patch fixes that.
Comment on attachment 8689297 [details] [diff] [review]
Have child send __delete__ in speech synth request protocol, fixes race.

+ if ((flags & eFailAtStart) != 0) {
I would just do
if (flags & eFailAtStart)
Attachment #8689297 - Flags: review?(bugs) → review+
https://hg.mozilla.org/mozilla-central/rev/a9f0334501a9
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.