update boost on linux
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
// ip/impl/basic_endpoint.hpp
|
||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
//
|
||||
// Copyright (c) 2003-2017 Christopher M. Kohlhoff (chris at kohlhoff dot com)
|
||||
// Copyright (c) 2003-2019 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)
|
||||
@@ -31,19 +31,7 @@ std::basic_ostream<Elem, Traits>& operator<<(
|
||||
const basic_endpoint<InternetProtocol>& endpoint)
|
||||
{
|
||||
boost::asio::ip::detail::endpoint tmp_ep(endpoint.address(), endpoint.port());
|
||||
boost::system::error_code ec;
|
||||
std::string s = tmp_ep.to_string(ec);
|
||||
if (ec)
|
||||
{
|
||||
if (os.exceptions() & std::basic_ostream<Elem, Traits>::failbit)
|
||||
boost::asio::detail::throw_error(ec);
|
||||
else
|
||||
os.setstate(std::basic_ostream<Elem, Traits>::failbit);
|
||||
}
|
||||
else
|
||||
for (std::string::iterator i = s.begin(); i != s.end(); ++i)
|
||||
os << os.widen(*i);
|
||||
return os;
|
||||
return os << tmp_ep.to_string().c_str();
|
||||
}
|
||||
|
||||
} // namespace ip
|
||||
|
||||
Reference in New Issue
Block a user