good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: threads::shared: lock a VARIABLEby hippo (Bishop) |
on Aug 22, 2016 at 14:44 UTC ( [id://1170174]=note: print w/replies, xml ) | Need Help?? |
threads::shared locks are advisory (see the docs). You have to test for it in your TryToReadLockVar thread rather than just altering it regardless of the lock.
In Section
Seekers of Perl Wisdom
|
|