[PATCH] Log alarms should be generated even if the QEMU process is not stopped

dinglimin dinglimin at cmss.chinamobile.com
Fri Sep 16 02:20:14 UTC 2022


Signed-off-by: dinglimin <dinglimin at cmss.chinamobile.com>
---
 src/qemu/qemu_process.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
index cbfdd3bda5..e025e10873 100644
--- a/src/qemu/qemu_process.c
+++ b/src/qemu/qemu_process.c
@@ -8006,9 +8006,11 @@ qemuProcessKill(virDomainObj *vm, unsigned int flags)
     }
 
     if (flags & VIR_QEMU_PROCESS_KILL_NOWAIT) {
-        virProcessKill(vm->pid,
+        if (virProcessKill(vm->pid,
                        (flags & VIR_QEMU_PROCESS_KILL_FORCE) ?
-                       SIGKILL : SIGTERM);
+                       SIGKILL : SIGTERM) != 0) {
+	    VIR_DEBUG("Failed to terminate qemu process");
+	}
         return 0;
     }
 
-- 
2.30.0.windows.2





More information about the libvir-list mailing list