From 41f7ea49cb97828faf44505968477b911ecfc367 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Tue, 21 Sep 2021 16:02:12 +0300 Subject: [PATCH] Do not use std::system_category under VS2013 --- include/boost/system/detail/error_category_impl.hpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/boost/system/detail/error_category_impl.hpp b/include/boost/system/detail/error_category_impl.hpp index 417f7da..cab08ab 100644 --- a/include/boost/system/detail/error_category_impl.hpp +++ b/include/boost/system/detail/error_category_impl.hpp @@ -121,9 +121,10 @@ inline error_category::operator std::error_category const & () const if( id_ == detail::system_category_id ) { -#if defined(__CYGWIN__) +#if defined(__CYGWIN__) || (defined(_MSC_VER) && _MSC_VER == 1800) // Under Cygwin, std::system_category() is POSIX + // Under VS2013, std::system_category() isn't quite right static const boost::system::detail::std_category system_instance( this, 0x1F4D7 ); return system_instance;