Beispiel #1
0
 inline auto accept(Acceptor& acceptor, Socket& socket, typename Acceptor::endpoint_type& endpoint, error_code& ec)
 {
     return make_awaiter<void>([&](auto&& cb)
     {
         acceptor.async_accept(socket, endpoint, std::move(cb));
     }, ec);
 }
Beispiel #2
0
 inline auto accept(Acceptor& acceptor, Socket& socket)
 {
     return make_awaiter<void>([&](auto&& cb)
     {
         acceptor.async_accept(socket, std::move(cb));
     });
 }