MCPcopy Create free account
hub / github.com/boostorg/beast / acceptor

Function acceptor

example/doc/ssl/server.cpp:62–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62net::awaitable<void>
63acceptor(ssl::context& ctx)
64{
65 auto executor = co_await net::this_coro::executor;
66 net::ip::tcp::endpoint endpoint{ {}, 8080 };
67 net::ip::tcp::acceptor acceptor{ executor, endpoint };
68
69 for(;;)
70 {
71 net::co_spawn(
72 executor,
73 handle_session({ co_await acceptor.async_accept(), ctx }),
74 print_exception);
75 }
76}
77
78int
79main()

Callers 1

mainFunction · 0.85

Calls 1

handle_sessionFunction · 0.85

Tested by

no test coverage detected