diff --git a/DataStructures/SharedMemoryFactory.h b/DataStructures/SharedMemoryFactory.h index f3d829681..b61a48b84 100644 --- a/DataStructures/SharedMemoryFactory.h +++ b/DataStructures/SharedMemoryFactory.h @@ -137,6 +137,15 @@ public: return RegionExists(key); } + template + static void RemoveSharedMemory( + const IdentifierT id + ) { + OSRMLockFile lock_file; + boost::interprocess::xsi_key key( lock_file().string().c_str(), id ); + RemoveSharedMemory(key); + } + private: static bool RegionExists( const boost::interprocess::xsi_key &key ) { bool result = true;