mirror of
https://github.com/dockur/windows.git
synced 2026-08-03 20:47:12 +01:00
fix: Show QEMU errors on unexpected exit (#1873)
This commit is contained in:
+13
-1
@@ -186,6 +186,12 @@ cleanupHelpers() {
|
||||
finish() {
|
||||
|
||||
local reason=$1
|
||||
local failed=0
|
||||
|
||||
if [ ! -f "$QEMU_END" ] && (( reason != 0 )); then
|
||||
failed=1
|
||||
fi
|
||||
|
||||
touch "$QEMU_END"
|
||||
|
||||
forceKillQemu "$reason"
|
||||
@@ -200,7 +206,13 @@ finish() {
|
||||
warn "Timed out while waiting for $(app) to exit!"
|
||||
fi
|
||||
|
||||
(( reason != 1 )) && echo && echo "❯ Shutdown completed!"
|
||||
echo
|
||||
|
||||
if (( failed == 0 )); then
|
||||
echo "❯ Shutdown completed!"
|
||||
else
|
||||
error "QEMU exited unexpectedly!"
|
||||
fi
|
||||
|
||||
exit "$reason"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user