summaryrefslogtreecommitdiff
path: root/boost/interprocess/windows_shared_memory.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/interprocess/windows_shared_memory.hpp')
-rw-r--r--boost/interprocess/windows_shared_memory.hpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/boost/interprocess/windows_shared_memory.hpp b/boost/interprocess/windows_shared_memory.hpp
index 5898b4b113..341674aec5 100644
--- a/boost/interprocess/windows_shared_memory.hpp
+++ b/boost/interprocess/windows_shared_memory.hpp
@@ -11,14 +11,19 @@
#ifndef BOOST_INTERPROCESS_WINDOWS_SHARED_MEMORY_HPP
#define BOOST_INTERPROCESS_WINDOWS_SHARED_MEMORY_HPP
-#if defined(_MSC_VER)
+#ifndef BOOST_CONFIG_HPP
+# include <boost/config.hpp>
+#endif
+#
+#if defined(BOOST_HAS_PRAGMA_ONCE)
# pragma once
#endif
#include <boost/interprocess/detail/config_begin.hpp>
#include <boost/interprocess/detail/workaround.hpp>
-#include <boost/detail/workaround.hpp>
+
#include <boost/interprocess/permissions.hpp>
+#include <boost/interprocess/detail/simple_swap.hpp>
#if !defined(BOOST_INTERPROCESS_WINDOWS)
#error "This header can only be used in Windows operating systems"
@@ -149,8 +154,8 @@ inline const char *windows_shared_memory::get_name() const
inline void windows_shared_memory::swap(windows_shared_memory &other)
{
- std::swap(m_handle, other.m_handle);
- std::swap(m_mode, other.m_mode);
+ (simple_swap)(m_handle, other.m_handle);
+ (simple_swap)(m_mode, other.m_mode);
m_name.swap(other.m_name);
}