#include #include #include #include typedef boost::shared_ptr safe_ipc_mx; static safe_ipc_mx __mx; int main(void) { system("pause"); try { __mx = safe_ipc_mx(new boost::interprocess::named_mutex(boost::interprocess::open_or_create_t(),"JAEGER")); std::cout << std::endl << "Mutex created !" << std::endl; } catch(boost::interprocess::interprocess_exception const& e) { std::cout << std::endl << "Mutex creation error " << e.what() << " /" << e.get_error_code() << " /" << e.get_native_error(); } system("pause"); return 0; }