Boost logo

Boost Users :

Subject: [Boost-users] [interprocess] remove
From: Moritz (mokoman_at_[hidden])
Date: 2009-08-28 09:25:36


Hi,

I have a question concerning the remove function of
managed_shared_memory. Actually I am not able to remove a segment of
shared memory. See the following example. It writes 0 to the output
stream. But why?

#include <boost/interprocess/managed_shared_memory.hpp>
#include <iostream>

int main()
{

  boost::interprocess::managed_shared_memory * managed_shm;
  managed_shm = new
boost::interprocess::managed_shared_memory(boost::interprocess::open_or_create,
"TestMem", 1024);
  delete managed_shm;

  std::cerr <<
boost::interprocess::shared_memory_object::remove("TestMem") << std::endl;
}


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