Closed
Bug 1067725
Opened 11 years ago
Closed 10 years ago
MediaDecoderReader waiting for resources (or ReadMetadata) should be async
Categories
(Core :: Audio/Video: Playback, defect)
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: cpearce, Unassigned)
References
Details
Attachments
(1 obsolete file)
The current MediaDecoderReader "waiting for resources" pattern is to have a function that the state machine polls to check whether it should call ReadMetadata() again (IsWaitingForResources()), and the state machine calls IsWaitingForResources() again after calling ReadMetadata() to check if it fails.
This is bad, because as we found with bug 1065855 there can be races W.R.T. the is waiting state changing and the return value of IsWaitingForResources() changing.
We fixed it in bug 1065855 by adding more polling, but that fix relies upon the Reader's IsWaitingForResources() syncing state on the decoder monitor, which implementations could easily forget to do.
Ideally we should make this wait async instead of polling, which is vulnerable to races.
Comment hidden (typo) |
Comment hidden (typo) |
Updated•10 years ago
|
Component: Audio/Video → Audio/Video: Playback
Updated•10 years ago
|
You need to log in
before you can comment on or make changes to this bug.
Description
•