Eliminate crash in Ctrl::GetOwner() when short live popup is being displayed (#315)

* Eliminate crash in Ctrl::GetOwner() when short live popup is being displayed

* .review
This commit is contained in:
Zbigniew Rębacz 2025-10-22 23:31:19 +02:00 committed by GitHub
parent 0850a738d8
commit ec98fe7179
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -122,7 +122,7 @@ Ctrl *Ctrl::GetOwner()
{
GuiLock __;
Top *top = GetTop();
return IsOpen() ? top->owner : NULL;
return top && IsOpen() ? top->owner : nullptr;
}
Ctrl *Ctrl::GetActiveCtrl()
@ -602,4 +602,6 @@ Vector<WString> SplitCmdLine__(const char *cmd)
}
#endif
#endif