summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/asio/include/asio/error_code.hpp
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/asio/include/asio/error_code.hpp')
-rw-r--r--3rdparty/asio/include/asio/error_code.hpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/3rdparty/asio/include/asio/error_code.hpp b/3rdparty/asio/include/asio/error_code.hpp
index 09a2acb2f6b..4026b9ca58f 100644
--- a/3rdparty/asio/include/asio/error_code.hpp
+++ b/3rdparty/asio/include/asio/error_code.hpp
@@ -2,7 +2,7 @@
// error_code.hpp
// ~~~~~~~~~~~~~~
//
-// Copyright (c) 2003-2016 Christopher M. Kohlhoff (chris at kohlhoff dot com)
+// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com)
//
// Distributed under the Boost Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
@@ -101,6 +101,20 @@ public:
*this = make_error_code(e);
}
+ /// Clear the error value to the default.
+ void clear()
+ {
+ value_ = 0;
+ category_ = &system_category();
+ }
+
+ /// Assign a new error value.
+ void assign(int v, const error_category& c)
+ {
+ value_ = v;
+ category_ = &c;
+ }
+
/// Get the error value.
int value() const
{