1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-02 00:10:22 +02:00

Merge pull request #5087 from Laserlicht/boost_update

fix boost 1.87
This commit is contained in:
Ivan Savenko 2024-12-17 12:30:14 +02:00 committed by GitHub
commit 09163009e7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 8 additions and 0 deletions

View File

@ -199,7 +199,11 @@ void NetworkConnection::close()
{
boost::system::error_code ec;
socket->close(ec);
#if BOOST_VERSION >= 108700
timer->cancel();
#else
timer->cancel(ec);
#endif
//NOTE: ignoring error code, intended
}

View File

@ -15,7 +15,11 @@
VCMI_LIB_NAMESPACE_BEGIN
#if BOOST_VERSION >= 108700
using NetworkContext = boost::asio::io_context;
#else
using NetworkContext = boost::asio::io_service;
#endif
using NetworkSocket = boost::asio::ip::tcp::socket;
using NetworkAcceptor = boost::asio::ip::tcp::acceptor;
using NetworkBuffer = boost::asio::streambuf;