Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/marian-nmt/Simple-WebSocket-Server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'asio_compatibility.hpp')
-rw-r--r--asio_compatibility.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/asio_compatibility.hpp b/asio_compatibility.hpp
index a9abd7c..3d2df07 100644
--- a/asio_compatibility.hpp
+++ b/asio_compatibility.hpp
@@ -42,9 +42,9 @@ namespace SimpleWeb {
inline asio::ip::address make_address(const std::string &str) noexcept {
return asio::ip::make_address(str);
}
- template <typename socket_type>
- asio::executor get_socket_executor(socket_type &socket) {
- return socket.get_executor();
+ template <typename socket_type, typename duration_type>
+ asio::steady_timer make_steady_timer(socket_type &socket, std::chrono::duration<duration_type> duration) {
+ return asio::steady_timer(socket.get_executor(), duration);
}
template <typename handler_type>
void async_resolve(asio::ip::tcp::resolver &resolver, const std::pair<std::string, std::string> &host_port, handler_type &&handler) {