#8008 closed Bugs (duplicate)
boost named_condition under Windows
Reported by: | Owned by: | Ion Gaztañaga | |
---|---|---|---|
Milestone: | To Be Determined | Component: | interprocess |
Version: | Boost 1.52.0 | Severity: | Problem |
Keywords: | Cc: |
Description
Simple problem, reduced to it's simplest form.
NamedConditionServer.cpp
#include <boost/interprocess/sync/named_mutex.hpp> #include <boost/interprocess/sync/named_condition.hpp> namespace ipc = boost::interprocess; int main() { unsigned long long count = 0; ipc::named_mutex myMutex( ipc::open_or_create, "BoostConditionTestMutex" ); ipc::named_condition myCondition( ipc::open_or_create, "BoostConditionTestCondition" ); ipc::scoped_lock<ipc::named_mutex> lock( myMutex ); for(;;) { myCondition.wait( lock ); std::cout << "Served # " << ++count << std::endl; } return 0; }
NamedConditionClient.cpp
#include <boost/interprocess/sync/named_mutex.hpp> #include <boost/interprocess/sync/named_condition.hpp> namespace ipc = boost::interprocess; int main() { ipc::named_condition myCondition( ipc::open_or_create, "BoostConditionTestCondition" ); myCondition.notify_one(); }
Under Linux, I can run the server in another window or the background and it responds as expected when I run the client.
On Windows7 (Visual Studio 2012 Update 1) however, the server never wakes up from the "wait".
I have tried under the debugger and have removed "C:\ProgramData\boost_interprocess" between runs to no avail.
After running, there is just one "BoostConditionTestCondition" and just one "BoostConditionTestMutex" file in the "C:\ProgramData\boost_interprocess" tree.
This appears to be a bug to me, but I'd welcome suggestions to the contrary.
Change History (4)
comment:1 by , 10 years ago
Resolution: | → duplicate |
---|---|
Status: | new → closed |
comment:3 by , 10 years ago
Replying to igaztanaga:
#7682 fixed, can you test if your bug was fixed?
Thanks!
It's a bug from work and I don't have the resources at home to do that. I will check on Monday US Pacific time, but it's a simple test that I'm sure someone else will probably have already run by then.
thanks for the report and specially the test case. It's a bug and it's a duplicate of #7682