Closed Bug 1196682 Opened 9 years ago Closed 9 years ago

[LayerScope] DebugDataSender is not thread safe

Categories

(Core :: Graphics, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla43
Tracking Status
firefox43 --- fixed

People

(Reporter: u459114, Assigned: u459114)

References

Details

Attachments

(1 file, 2 obsolete files)

Fix DebugDataSender::mList is accessable in both main and compositor thread.
Attached patch DebugDataSender thread safe (obsolete) (deleted) — Splinter Review
Attached patch DebugDataSender thread safe (obsolete) (deleted) — Splinter Review
Hi Dan, Please help to review this change. When TingYu using LayerScope on debugging display list, he met an assertion on debug build. I found another thread-safe problem, which existed for a long time, in layerscope while addressing the root cause of that assertion.
Attachment #8650394 - Attachment is obsolete: true
Attachment #8650396 - Flags: review?(dglastonbury)
CJ, your patch works for me. I no longer hit the assert in layerscope anymore.
Comment on attachment 8650396 [details] [diff] [review] DebugDataSender thread safe Review of attachment 8650396 [details] [diff] [review]: ----------------------------------------------------------------- Sorry for the delayed review. LGTM with fixing the nits. ::: gfx/layers/LayerScope.cpp @@ +126,5 @@ > + // TBD: RemoveConnection is executed on the compositor thread and > + // AddConntection is executed on the main thread, which might be > + // a problem if a user disconnect and connect readlly quickly at > + // viewer side. > + // We should dispatch RemoveConnection onto main thead. // TBD: RemoveConnection is executed on the compositor thread and // AddConnection is executed on the main thread, which might be // a problem if a user disconnect and connect really quickly on // viewer side. // We should dispatch RemoveConnection from main thread. @@ +752,2 @@ > > + friend class AppenTask; AppendTask? If code compiles with this typo, then the friend declaration isn't required. @@ +772,5 @@ > > + DebugGLData *mData; > + // Keep a strong reference to DebugDataSender to prevent we try to > + // access mHost on mThread, while it's been destroyed on the main > + // thread. // Keep a strong reference to DebugDataSender to prevent UAF // access mHost on mThread, when it's been destroyed on the main // thread.
Attachment #8650396 - Flags: review?(dglastonbury) → review+
Attached patch DebugDataSender thread safe (deleted) — Splinter Review
Attachment #8650396 - Attachment is obsolete: true
Attachment #8651675 - Flags: review+
Keywords: checkin-needed
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: