mirror of
https://github.com/boostorg/interprocess.git
synced 2026-01-26 18:42:14 +00:00
Merge from trunk for 1.46
[SVN r68072]
This commit is contained in:
@@ -16,15 +16,32 @@
|
||||
#include <cstddef>
|
||||
#include <cstdio>
|
||||
|
||||
//<-
|
||||
#include "../test/get_process_id_name.hpp"
|
||||
//->
|
||||
|
||||
using namespace boost::interprocess;
|
||||
typedef list<int, allocator<int, managed_mapped_file::segment_manager> >
|
||||
MyList;
|
||||
|
||||
int main ()
|
||||
{
|
||||
{
|
||||
//Define file names
|
||||
//<-
|
||||
#if 1
|
||||
std::string file(boost::interprocess::detail::get_temporary_path());
|
||||
file += "/"; file += test::get_process_id_name();
|
||||
const char *FileName = file.c_str();
|
||||
#else
|
||||
//->
|
||||
const char *FileName = "file_mapping";
|
||||
//<-
|
||||
#endif
|
||||
//->
|
||||
|
||||
const std::size_t FileSize = 1000;
|
||||
file_mapping::remove(FileName);
|
||||
|
||||
try{
|
||||
std::size_t old_size = 0;
|
||||
managed_mapped_file::handle_t list_handle;
|
||||
|
||||
Reference in New Issue
Block a user