////////////////////////////////////////////////////////////////////////////// // // (C) Copyright Ion Gaztaņaga 2006. Distributed under the Boost // Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // // See http://www.boost.org/libs/interprocess for documentation. // ////////////////////////////////////////////////////////////////////////////// #include #include #include #include #include #include #include "allocation_test_template.hpp" #include int main () { using namespace boost::interprocess; const int memsize = 16384; const char *const shMemName = "MySharedMemory"; { //A shared memory with simple sequential fit algorithm typedef basic_managed_shared_memory > ,null_index > my_managed_shared_memory; //Create shared memory shared_memory_object::remove(shMemName); my_managed_shared_memory segment(create_only, shMemName, memsize); //Now take the segment manager and launch memory test if(!test::test_all_allocation(*segment.get_segment_manager())){ return 1; } } return 0; } #include