Fix xwayland-game-wrapper, again
This commit is contained in:
parent
583ef3b7e1
commit
ef54cca933
@ -88,7 +88,7 @@ done
|
|||||||
(( "${OPTIND}" > ${#} )) && print_help "${0}"
|
(( "${OPTIND}" > ${#} )) && print_help "${0}"
|
||||||
shift $(( "${OPTIND}" - 1))
|
shift $(( "${OPTIND}" - 1))
|
||||||
|
|
||||||
function () {
|
function {
|
||||||
emulate -L zsh
|
emulate -L zsh
|
||||||
setopt errexit
|
setopt errexit
|
||||||
[[ -v window_manager ]] ||
|
[[ -v window_manager ]] ||
|
||||||
@ -106,7 +106,7 @@ function on_sigchld {
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
#trap on_sigchld CHLD
|
trap on_sigchld CHLD
|
||||||
|
|
||||||
coproc Xwayland -fullscreen -geometry "${resolution}" -displayfd 1
|
coproc Xwayland -fullscreen -geometry "${resolution}" -displayfd 1
|
||||||
local xwayland_display
|
local xwayland_display
|
||||||
@ -119,7 +119,10 @@ cat <&p >&2
|
|||||||
let cat_pid="${!}"
|
let cat_pid="${!}"
|
||||||
|
|
||||||
sh -c "exec -- ${window_manager}" &
|
sh -c "exec -- ${window_manager}" &
|
||||||
sh -c "exec -- ${@}"
|
function {
|
||||||
|
emulate -L sh
|
||||||
|
eval "${@}"
|
||||||
|
} "${@}"
|
||||||
let child_error_code="${?}"
|
let child_error_code="${?}"
|
||||||
if (( ${child_error_code} )); then
|
if (( ${child_error_code} )); then
|
||||||
printf 'Child exited with error code %d\n' "${child_error_code}"
|
printf 'Child exited with error code %d\n' "${child_error_code}"
|
||||||
|
Loading…
Reference in New Issue
Block a user