浏览代码

fix: Prevent re-entry during shutdown (#176)

Kroese 1 年之前
父节点
当前提交
0f2717fec4
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/power.sh

+ 2 - 0
src/power.sh

@@ -50,6 +50,8 @@ finish() {
   local pid
   local reason=$1
 
+  touch "$QEMU_END"
+
   if [ -f "$QEMU_PID" ]; then
 
     pid=$(<"$QEMU_PID")