Closed Bug 1160064 Opened 10 years ago Closed 10 years ago

Give WatchManager an owner thread and manage lifetimes better

Categories

(Core :: Audio/Video, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla40
Tracking Status
firefox40 --- fixed

People

(Reporter: bholley, Assigned: bholley)

References

Details

Attachments

(5 files)

Followup from bug 1159558.
The goal here is to hoist all meaningful watcher/mirror/canonical manipulation onto the owner thread. But since that must necessarily happen asynchronously, we need to make sure that canonicals are in a sane state immediately upon creation, since otherwise a mirror from another thread may attempt to connect to a not-yet-initialized canonical.
Attachment #8600178 - Flags: review?(jwwang)
We take this as an opportunity to remove connect-during-initialization. Always connecting from the owner thread feels like a stronger invariant.
Attachment #8600179 - Flags: review?(jwwang)
Attachment #8600177 - Flags: review?(jwwang) → review+
Attachment #8600178 - Flags: review?(jwwang) → review+
The patches in this bug can cause us to log things before some of the Ensure*Log macros are called. Let's just do this right.
Attachment #8600210 - Flags: review?(jwwang)
Attachment #8600179 - Flags: review?(jwwang) → review+
Attachment #8600210 - Flags: review?(jwwang) → review+
Comment on attachment 8600180 [details] [diff] [review] Part 4 - Give WatchManager an owner thread and make sure everything happens there. v1 Review of attachment 8600180 [details] [diff] [review]: ----------------------------------------------------------------- Good!
Attachment #8600180 - Flags: review?(jwwang) → review+
This breaks building when PR_LOGGING is not set due to line 130: gMediaDecoderLog = PR_NewLogModule("MediaDecoder"); Suggest wrapping that line with: #ifdef PR_LOGGING gMediaDecoderLog = PR_NewLogModule("MediaDecoder"); #endif since the extern is only defined when PR_LOGGING is defined.
I have created a new bug to track the build breakage: bug 1161186
Depends on: 1259473
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: