Boost C++ Libraries: Ticket #9642: Possible race condition in boost::interprocess::message_queue creation https://svn.boost.org/trac10/ticket/9642 <p> Dear folks, </p> <p> I am trying to debug sporadic access violations that occur inside a boost::interprocess message queue. (access violation reading an address in the shared memory region). </p> <p> Environment: boost 1.54, VC++2010. Occurs in both Debug &amp; Release builds. </p> <p> It always occurs on or about line 854 (in case of reception) in message_queue.hpp: Comments were added by me </p> <blockquote> <p> recvd_size = top_msg.len; <em> top_msg points to invalid location </em></p> </blockquote> <p> Or line 756 (in case of sending) </p> <p> BOOST_ASSERT(free_msg_hdr.priority == 0); <em> free_msg_hdr points to invalid location </em></p> <p> Please see this S/O link for the entire question, plus sample code that reproduces the problem for me: </p> <p> <a class="ext-link" href="http://stackoverflow.com/questions/21628306/boostinterprocess-message-queue-race-condition-on-creation"><span class="icon">​</span>http://stackoverflow.com/questions/21628306/boostinterprocess-message-queue-race-condition-on-creation</a> </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/9642 Trac 1.4.3