diff options
Diffstat (limited to 'library/cpp/threading/equeue')
| -rw-r--r-- | library/cpp/threading/equeue/fast/equeue.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/library/cpp/threading/equeue/fast/equeue.h b/library/cpp/threading/equeue/fast/equeue.h index a24f0e83a9f..0463507a55b 100644 --- a/library/cpp/threading/equeue/fast/equeue.h +++ b/library/cpp/threading/equeue/fast/equeue.h @@ -111,7 +111,7 @@ public: while (true) { IObjectInQueue* job = nullptr; - while (thisThreadId >= ActiveThreadCount_) { + while (thisThreadId >= ActiveThreadCount_ && !Stopped_) { Sleep(TDuration::Seconds(1)); } @@ -146,7 +146,7 @@ public: } void SetCurrentMaxQueueSize(size_t v) { - Y_ENSURE(v < MaxQueueSize_); + Y_ENSURE(v <= MaxQueueSize_); CurrentMaxQueueSize_ = v; } |
