summaryrefslogtreecommitdiff
path: root/boost/process/detail/config.hpp
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2019-12-05 15:12:59 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2019-12-05 15:12:59 +0900
commitb8cf34c691623e4ec329053cbbf68522a855882d (patch)
tree34da08632a99677f6b79ecb65e5b655a5b69a67f /boost/process/detail/config.hpp
parent3fdc3e5ee96dca5b11d1694975a65200787eab86 (diff)
downloadboost-b8cf34c691623e4ec329053cbbf68522a855882d.tar.gz
boost-b8cf34c691623e4ec329053cbbf68522a855882d.tar.bz2
boost-b8cf34c691623e4ec329053cbbf68522a855882d.zip
Imported Upstream version 1.67.0upstream/1.67.0
Diffstat (limited to 'boost/process/detail/config.hpp')
-rw-r--r--boost/process/detail/config.hpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/boost/process/detail/config.hpp b/boost/process/detail/config.hpp
index e668811cd5..dfea2c3bb7 100644
--- a/boost/process/detail/config.hpp
+++ b/boost/process/detail/config.hpp
@@ -82,6 +82,17 @@ inline void throw_last_error()
throw process_error(get_last_error());
}
+inline void throw_error(const std::error_code& ec)
+{
+ if (ec)
+ throw process_error(ec);
+}
+
+inline void throw_error(const std::error_code& ec, const char* msg)
+{
+ if (ec)
+ throw process_error(ec, msg);
+}
template<typename Char> constexpr Char null_char();
template<> constexpr char null_char<char> (){return '\0';}