DescriptionFixing race between ~AsyncInvoker and ~AsyncClosure.
The AsyncInvoker destructor waits for all invoked tasks to be complete
(in other words, all AsyncClosures to be destructed). They were using an
event to wake up the destructor, but a race made it possible for this
event to be dereferenced after it's destroyed.
So, instead of using an event, this CL just busy-waits until the tasks
are complete. The advantage of this approach is that the tasks
themselves don't need to do any additional synchronization, which could
harm performance since tasks are invoked much more often than
AsyncInvokers are destroyed.
BUG=webrtc:7656
Patch Set 1 #
Total comments: 3
Messages
Total messages: 10 (3 generated)
|