Boost logo

Boost Users :

From: Rene Rivera (grafik.list_at_[hidden])
Date: 2005-04-10 11:21:06


Peter Dimov wrote:
> Rene Rivera wrote:
[...]
> This is not equivalent to the above scenario. You can't have two threads
> calling lock() at the same time, because a scoped_lock object (as
> currently specified) is not thread safe (whereas a mutex is, by its very
> nature.)
[...]
> This is also not quite equivalent to the original. In it, a lock() op1()
> op2() unlock() is a transaction; no other thread can inject its own op3
> between op1 and op2.

Just goes to show how easy it is to shoot the foot off :-)

-- 
-- Grafik - Don't Assume Anything
-- Redshift Software, Inc. - http://redshift-software.com
-- rrivera/acm.org - grafik/redshift-software.com
-- 102708583/icq - grafikrobot/aim - Grafik/jabber.org

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net