ZLMediaKit / ZLToolKit

一个基于C++11的轻量级网络框架,基于线程池技术可以实现大并发网络IO
MIT License
1.98k stars 588 forks source link

防止短期获取同一个poller对象,当所有线程的负载都是0时,min_load == 0会直接breadk,导致thread_pos不会加1 #199

Closed scopys closed 11 months ago

scopys commented 11 months ago

在WorkThreadPool::Instance()->getPoller()的线程中又再次调用WorkThreadPool::Instance()->getPoller(),而计算负载的可能还是0,从而获取到了同一个poller

CLAassistant commented 11 months ago

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


zhaochaoping seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.