core: guard workspace and monitor in moveWorkspaceToMonitor

ref #7822
This commit is contained in:
Vaxry 2025-01-04 00:10:10 +01:00
parent f69e72eca1
commit 2e6e0e9278

View file

@ -2076,7 +2076,8 @@ PHLMONITOR CCompositor::getMonitorFromString(const std::string& name) {
void CCompositor::moveWorkspaceToMonitor(PHLWORKSPACE pWorkspace, PHLMONITOR pMonitor, bool noWarpCursor) {
// We trust the monitor to be correct.
if (!pWorkspace || !pMonitor)
return;
if (pWorkspace->m_pMonitor == pMonitor)
return;