diff options
author | ilnurkh <ilnurkh@yandex-team.com> | 2023-10-09 23:39:40 +0300 |
---|---|---|
committer | ilnurkh <ilnurkh@yandex-team.com> | 2023-10-09 23:57:14 +0300 |
commit | e601ca03f859335d57ecff2e5aa6af234b6052ed (patch) | |
tree | de519a847e58a1b3993fcbfe05ff44cc946a3e24 /library/cpp/messagebus/event_loop.cpp | |
parent | bbf2b6878af3854815a2c0ecb07a687071787639 (diff) | |
download | ydb-e601ca03f859335d57ecff2e5aa6af234b6052ed.tar.gz |
Y_VERIFY->Y_ABORT_UNLESS at ^l
https://clubs.at.yandex-team.ru/arcadia/29404
Diffstat (limited to 'library/cpp/messagebus/event_loop.cpp')
-rw-r--r-- | library/cpp/messagebus/event_loop.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/library/cpp/messagebus/event_loop.cpp b/library/cpp/messagebus/event_loop.cpp index 4240a5cd96c..9a9d90508d5 100644 --- a/library/cpp/messagebus/event_loop.cpp +++ b/library/cpp/messagebus/event_loop.cpp @@ -280,7 +280,7 @@ TEventLoop::TImpl::TImpl(const char* name) void TEventLoop::TImpl::Run() { bool res = AtomicCas(&RunningState, EVENT_LOOP_RUNNING, EVENT_LOOP_CREATED); - Y_VERIFY(res, "Invalid mbus event loop state"); + Y_ABORT_UNLESS(res, "Invalid mbus event loop state"); if (!!Name) { SetCurrentThreadName(Name); @@ -308,7 +308,7 @@ void TEventLoop::TImpl::Run() { SOCKET socket = -1; while (SocketsToRemove.Dequeue(&socket)) { TGuard<TMutex> guard(Mutex); - Y_VERIFY(Data.erase(socket) == 1, "must be removed once"); + Y_ABORT_UNLESS(Data.erase(socket) == 1, "must be removed once"); } } @@ -324,7 +324,7 @@ void TEventLoop::TImpl::Run() { res = AtomicCas(&RunningState, EVENT_LOOP_STOPPED, EVENT_LOOP_RUNNING); - Y_VERIFY(res); + Y_ABORT_UNLESS(res); StoppedEvent.Signal(); } @@ -340,13 +340,13 @@ void TEventLoop::TImpl::Stop() { } TChannelPtr TEventLoop::TImpl::Register(TSocket socket, TEventHandlerPtr eventHandler, void* cookie) { - Y_VERIFY(socket != INVALID_SOCKET, "must be a valid socket"); + Y_ABORT_UNLESS(socket != INVALID_SOCKET, "must be a valid socket"); TChannelPtr channel = new TChannel(new TChannel::TImpl(this, socket, eventHandler, cookie)); TGuard<TMutex> guard(Mutex); - Y_VERIFY(Data.insert(std::make_pair(socket, channel)).second, "must not be already inserted"); + Y_ABORT_UNLESS(Data.insert(std::make_pair(socket, channel)).second, "must not be already inserted"); return channel; } |