async read from socket

This commit is contained in:
Антон 2024-04-05 08:13:49 +03:00
parent 1f7c6d0703
commit 9632b749f4
1 changed files with 1 additions and 1 deletions

View File

@ -46,7 +46,7 @@ void ReadFromSocket(std::shared_ptr<net::ip::tcp::socket> sock)
s->sock = sock;
s->buf_size = message_size;
s->sock->async_read_some(net::buffer(s->buf.get(), s->buf_size),
s->sock->async_read_some(asio::buffer(s->buf.get(), s->buf_size),
std::bind(Callback, placeholders::_1, placeholders::_2, s));
}