Opened 17 years ago
Closed 17 years ago
#5516 closed defect (fixed)
missing lock for readblocksize member variable
| Reported by: | Owned by: | Isaac Richards | |
|---|---|---|---|
| Priority: | trivial | Milestone: | unknown |
| Component: | mythtv | Version: | head |
| Severity: | low | Keywords: | |
| Cc: | Ticket locked: | no |
Description
Turns out the readblocksize member variable in RingBuffer requires locking.
I have heard before that g++ is atomic about single variable assignments. But I don't know if that applies in this case.
Attachments (1)
Change History (2)
by , 17 years ago
| Attachment: | libs_libmythtv-missing-lock.patch added |
|---|
comment:1 by , 17 years ago
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
(In [17937]) Fixes #5516. Improper locking in RingBuffer class.
I didn't use Erik's patch because it didn't really address the problem, two different locks were being used to independently to protect the same 'readblocksize' variable. But the report pointed me in the right direction.
Note:
See TracTickets
for help on using tickets.

wraps readblocksize with a lock