summaryrefslogtreecommitdiff
path: root/boost/interprocess/detail/file_wrapper.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/interprocess/detail/file_wrapper.hpp')
-rw-r--r--boost/interprocess/detail/file_wrapper.hpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/boost/interprocess/detail/file_wrapper.hpp b/boost/interprocess/detail/file_wrapper.hpp
index 507ec478dc..58f28e97f8 100644
--- a/boost/interprocess/detail/file_wrapper.hpp
+++ b/boost/interprocess/detail/file_wrapper.hpp
@@ -11,7 +11,11 @@
#ifndef BOOST_INTERPROCESS_DETAIL_FILE_WRAPPER_HPP
#define BOOST_INTERPROCESS_DETAIL_FILE_WRAPPER_HPP
-#if defined(_MSC_VER)
+#ifndef BOOST_CONFIG_HPP
+# include <boost/config.hpp>
+#endif
+#
+#if defined(BOOST_HAS_PRAGMA_ONCE)
# pragma once
#endif
@@ -21,6 +25,7 @@
#include <boost/interprocess/creation_tags.hpp>
#include <boost/move/utility_core.hpp>
#include <boost/interprocess/creation_tags.hpp>
+#include <boost/interprocess/detail/simple_swap.hpp>
namespace boost {
namespace interprocess {
@@ -127,8 +132,8 @@ inline bool file_wrapper::get_size(offset_t &size) const
inline void file_wrapper::swap(file_wrapper &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_filename.swap(other.m_filename);
}