Boost logo

Boost :

Subject: Re: [boost] [Interprocess::Semaphore] Deadlock on more producers - one consumer problem
From: Ion Gaztañaga (igaztanaga_at_[hidden])
Date: 2009-06-22 11:53:09


Cosimo Calabrese wrote:
>>
>> Yes, I think you are right. post() should unconditionally
>> notify_one(), otherwise, we could post() several times and only wake
>> up one thread.
>>
>> Can you test your code removing the m_count == 0 condition?
>>
>
> Well, I've removed the m_count == 0 condition and it seems to work
> properly. Every time a protected resource is freed, a notify_one() is
> performed and a locked thread is unlocked.
>
> Do you take in consideration a correction in a next boost release?

Yes, boost 1.40 will have this correction.

> Best,
> Cosimo Calabrese.

Best,

Ion


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk