Skip to content

Commit 0f8712e

Browse files
committed
fix crash in moveWorkspaceToMonitor
1 parent 3e28a8b commit 0f8712e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/managers/KeybindManager.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -775,6 +775,11 @@ void CKeybindManager::moveWorkspaceToMonitor(std::string args) {
775775

776776
const auto PWORKSPACE = g_pCompositor->getWorkspaceByID(WORKSPACEID);
777777

778+
if (!PWORKSPACE) {
779+
Debug::log(ERR, "moveWorkspaceToMonitor workspace doesn't exist!");
780+
return;
781+
}
782+
778783
g_pCompositor->moveWorkspaceToMonitor(PWORKSPACE, PMONITOR);
779784
}
780785

0 commit comments

Comments
 (0)