101 if (address ==
nullptr)
return false;
104 for (
size_t i = 0; i < threads; ++i) {
106 if (sub_socket == -1) {
115 socketVector.emplace_back(sub_socket);
118 for (
size_t i = 0; i < threads; ++i) {
119 auto event = creator();
120 if (event ==
nullptr) {
123 event->setListenFd(
static_cast<int>(socketVector[i]));
124 if (!event->init()) {
128 eventLoopVector.emplace_back(event);
135 for (
decltype(
auto) event_loop: eventLoopVector) {
138 eventLoopVector.clear();
141 for (
decltype(
auto) sub_socket: socketVector) {
144 socketVector.clear();