id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 11724,managed_shared_memory constructor crash,john.saxton@…,Ion Gaztañaga,"If my system has zero shared memory available and I invoke the managed_shared_memory constructor, the constructor will crash. I am able to consistently reproduce this on Centos 6.5 using g++ 4.4.7 and Boost v1.59. My repro case is very Linux-specific: 1: rm /dev/shm/foobar 2: dd if=/dev/zero of=/dev/shm/fill (the command will terminate once all shared memory on the system is exhausted) 3: Build the attached C++ file (I used g++ -g -I/path/to/boost/ -lpthread -lrt shm.cpp) 4: Run the resulting executable, it should crash {{{ (gdb) where #0 0x0000000000402186 in boost::interprocess::ipcdetail::atomic_cas32 (mem=0x7ffff7ee3000, with=1, cmp=0) at /home/elemental/boost_1_5_9/boost_1_59_0/boost/interprocess/detail/atomic.hpp:141 #1 0x000000000040389c in boost::interprocess::ipcdetail::managed_open_or_create_impl::priv_open_or_create, 0ul>, boost::interprocess::iset_index, 16ul> > > (this= 0x7fffffffe0f8, type=boost::interprocess::ipcdetail::DoCreate, id=@0x7fffffffe090, size=1048576, mode=boost::interprocess::read_write, addr=0x0, perm=..., construct_func=...) at /home/elemental/boost_1_5_9/boost_1_59_0/boost/interprocess/detail/managed_open_or_create_impl.hpp:409 #2 0x0000000000403163 in boost::interprocess::ipcdetail::managed_open_or_create_impl::managed_open_or_create_impl, 0ul>, boost::interprocess::iset_index, 16ul> > > (this=0x7fffffffe0f8, id=@0x7fffffffe090, size=1048576, mode=boost::interprocess::read_write, addr=0x0, construct_func=..., perm=...) at /home/elemental/boost_1_5_9/boost_1_59_0/boost/interprocess/detail/managed_open_or_create_impl.hpp:184 #3 0x0000000000402f2b in boost::interprocess::basic_managed_shared_memory, 0ul>, boost::interprocess::iset_index>::basic_managed_shared_memory (this=0x7fffffffe0f0, name=0x4077fb ""foobar"", size=1048576, addr=0x0, perm=...) at /home/elemental/boost_1_5_9/boost_1_59_0/boost/interprocess/managed_shared_memory.hpp:106 #4 0x00000000004016a2 in main (argc=1, argv=0x7fffffffe228) at shm.cpp:23 }}} ",Bugs,new,To Be Determined,interprocess,Boost 1.59.0,Problem,,,