Fix hyprctl crash when screensaver is terminated (#4045)

Redirect hyprctl output in exit_screensaver() to prevent SIGABRT crash
when the screensaver window is closed externally (via keybind or lock screen).

The crash occurs because hyprctl's std::println() throws when writing to
a broken stdout after the terminal is killed.
This commit is contained in:
LunarLollipop
2026-01-07 19:52:52 +02:00
committed by GitHub
parent f7f28bb655
commit 76b3e68c97

View File

@@ -7,7 +7,7 @@ screensaver_in_focus() {
}
exit_screensaver() {
hyprctl keyword cursor:invisible false
hyprctl keyword cursor:invisible false &>/dev/null || true
pkill -x tte 2>/dev/null
pkill -f org.omarchy.screensaver 2>/dev/null
exit 0