This commit is contained in:
azw 2023-05-07 01:57:22 +00:00
parent e41ffbd58f
commit be09f290d0

View File

@ -23,7 +23,7 @@ std::shared_ptr<asio::io_context> IoMgr::GetIoContext(int type)
{
if (type >= 0 && type < io_contexts_.size()) {
auto& contexts = io_contexts_.at(type);
if (contexts.empty()) {
if (!contexts.empty()) {
return contexts.at(rand() % contexts.size());
}
}