e5deabe0aa
The \0 after error code prevent logging error message which is after it. This change clobber qubesd-query exit code with tr exit code (mostly 0), but this is a good thing - failing qubes-suspend service does not prevent the suspend, but do prevent the stop hooks being called, which for example breaks time synchronization or may leave some domains paused. QubesOS/qubes-issues#3489
13 lines
336 B
Bash
Executable File
13 lines
336 B
Bash
Executable File
#!/bin/sh
|
|
|
|
case "$1" in
|
|
suspend|hibernate)
|
|
qubesd-query -e --fail -c /var/run/qubesd.internal.sock \
|
|
dom0 internal.SuspendPre dom0 | tr '\0' ' '
|
|
;;
|
|
resume|thaw)
|
|
qubesd-query -e --fail -c /var/run/qubesd.internal.sock \
|
|
dom0 internal.SuspendPost dom0 | tr '\0' ' '
|
|
;;
|
|
esac
|