LibCore: Assert instead of crashing in CEventLoop::current()

This commit is contained in:
Sergey Bugaev 2019-11-26 18:51:18 +03:00 committed by Andreas Kling
parent 8aef0a0755
commit 2f9be662ef
Notes: sideshowbarker 2024-07-19 11:04:23 +09:00

View file

@ -176,7 +176,9 @@ CEventLoop& CEventLoop::main()
CEventLoop& CEventLoop::current()
{
return *s_event_loop_stack->last();
CEventLoop* event_loop = s_event_loop_stack->last();
ASSERT(event_loop != nullptr);
return *event_loop;
}
void CEventLoop::quit(int code)