mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2025-11-11 12:33:42 +08:00
fix: Detect device
* fix: Detect device
This commit is contained in:
10
src/power.sh
10
src/power.sh
@@ -61,10 +61,14 @@ _graceful_shutdown() {
|
||||
local code=$?
|
||||
local pid cnt response
|
||||
|
||||
[ -f "$QEMU_COUNT" ] && return
|
||||
echo 0 > "$QEMU_COUNT"
|
||||
|
||||
set +e
|
||||
|
||||
if [ -f "$QEMU_COUNT" ]; then
|
||||
echo && info "Ignored $1 signal, already shutting down..."
|
||||
return
|
||||
fi
|
||||
|
||||
echo 0 > "$QEMU_COUNT"
|
||||
echo && info "Received $1 signal, sending shutdown command..."
|
||||
|
||||
if [ ! -f "$QEMU_PID" ]; then
|
||||
|
||||
Reference in New Issue
Block a user