summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp')
-rw-r--r--3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp b/3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp
index 0004e124ff6..7744d630cb9 100644
--- a/3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp
+++ b/3rdparty/asio/src/examples/cpp11/futures/daytime_client.cpp
@@ -2,7 +2,7 @@
// daytime_client.cpp
// ~~~~~~~~~~~~~~~~~~
//
-// 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)
@@ -77,7 +77,8 @@ int main(int argc, char* argv[])
// We run the io_context off in its own thread so that it operates
// completely asynchronously with respect to the rest of the program.
asio::io_context io_context;
- auto work = asio::make_work_guard(io_context);
+ auto work = asio::require(io_context.get_executor(),
+ asio::execution::outstanding_work.tracked);
std::thread thread([&io_context](){ io_context.run(); });
get_daytime(io_context, argv[1]);