Opened on 03/31/2017 at 06:49:50 PM
Closed on 04/05/2017 at 08:26:04 AM
#5082 closed defect (fixed)
Possible race condition in DefaultTimer
Reported by: | sergz | Assignee: | sergz |
---|---|---|---|
Priority: | P2 | Milestone: | |
Module: | Libadblockplus | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Platform: | Unknown / Cross platform | |
Ready: | no | Confidential: | no |
Tester: | Unknown | Verified working: | no |
Review URL(s): |
Description
Conditional variable requires that the values changing the return value of predicate are changed with acquired lock.
http://en.cppreference.com/w/cpp/thread/condition_variable
What to change
So far, simply moving assignment of shouldThreadStop member in destructor to a scope with std::lock_guard is enough.
Attachments (0)
Change History (5)
comment:1 Changed on 04/04/2017 at 10:48:20 AM by sergz
- Owner set to sergz
comment:2 Changed on 04/04/2017 at 10:48:58 AM by sergz
- Summary changed from Possble race conditon in DefaultTimer to Possible race condition in DefaultTimer
comment:3 Changed on 04/04/2017 at 10:53:44 AM by sergz
- Review URL(s) modified (diff)
- Status changed from new to reviewing
comment:4 Changed on 04/05/2017 at 08:25:36 AM by abpbot
comment:5 Changed on 04/05/2017 at 08:26:04 AM by sergz
- Resolution set to fixed
- Status changed from reviewing to closed
Note: See
TracTickets for help on using
tickets.
A commit referencing this issue has landed:
Issue 5082 - fix possible race condition in DefaultTimer