From 1b7899743c1caa4d11ea4b77712e654d1dcf9717 Mon Sep 17 00:00:00 2001 From: sha512sum Date: Fri, 26 Apr 2024 13:44:14 +0000 Subject: [PATCH] Update network facade --- include/cserver/engine/network.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/cserver/engine/network.hpp b/include/cserver/engine/network.hpp index 33713ce..7e32a5b 100644 --- a/include/cserver/engine/network.hpp +++ b/include/cserver/engine/network.hpp @@ -134,9 +134,9 @@ inline constexpr auto AsyncRead(Socket&& socket, Buffer buffer, CompletionCondit return boost::asio::async_read(std::forward(socket).impl, std::move(buffer), std::move(completion), boost::asio::use_awaitable); }; -template -inline constexpr auto AsyncReadUntil(TcpSocket& socket, Buffer buffer, Match match) -> Task<> { - return boost::asio::async_read_until(socket.impl, std::move(buffer), std::move(match), boost::asio::use_awaitable); +template +inline constexpr auto AsyncReadUntil(Socket&& socket, Buffer buffer, Match match) -> Task<> { + return boost::asio::async_read_until(std::forward(socket).impl, std::move(buffer), std::move(match), boost::asio::use_awaitable); }; inline constexpr auto TransferAll() {