Boost logo

Boost Users :

Subject: Re: [Boost-users] [Interprocess] deadlocking race condition in emulation interprocess_condition.hpp
From: Ion Gaztañaga (igaztanaga_at_[hidden])
Date: 2009-09-16 08:39:11


Young, Zachariah L escribió:

> My straightforward idea is to add the following line at line 172 of
> boost/interprocess/sync/emulation/interprocess_condition.hpp:
>
> if(!lock){
>
> detail::atomic_dec32(const_cast<boost::uint32_t*>(&m_num_waiters));
> timed_out = true;
> unlock_enter_mut = true;
> break;
> }

I think you are right. The count should be decremented because this
thread will exit the wait logic .

thanks,

Ion


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