From cc121412fc1ab0e7cc4578045a356dc7a195b4ba Mon Sep 17 00:00:00 2001 From: Peter Krempa Date: Tue, 20 Jul 2021 10:05:06 +0200 Subject: [PATCH] qemu: Remove return value from qemuMonitorDomainDeviceDeletedCallback MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change the callback prototype and fix the callback registered in the process code. Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- src/qemu/qemu_monitor.h | 8 ++++---- src/qemu/qemu_process.c | 4 ++-- src/qemu/qemu_processpriv.h | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/qemu/qemu_monitor.h b/src/qemu/qemu_monitor.h index f9eba2e647..c867466104 100644 --- a/src/qemu/qemu_monitor.h +++ b/src/qemu/qemu_monitor.h @@ -238,10 +238,10 @@ typedef void (*qemuMonitorDomainGuestPanicCallback)(qemuMonitor *mon, virDomainObj *vm, qemuMonitorEventPanicInfo *info, void *opaque); -typedef int (*qemuMonitorDomainDeviceDeletedCallback)(qemuMonitor *mon, - virDomainObj *vm, - const char *devAlias, - void *opaque); +typedef void (*qemuMonitorDomainDeviceDeletedCallback)(qemuMonitor *mon, + virDomainObj *vm, + const char *devAlias, + void *opaque); typedef int (*qemuMonitorDomainNicRxFilterChangedCallback)(qemuMonitor *mon, virDomainObj *vm, const char *devAlias, diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index 69be76ad96..4ca0ca3a10 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -1297,7 +1297,7 @@ qemuProcessHandleGuestPanic(qemuMonitor *mon G_GNUC_UNUSED, } -int +void qemuProcessHandleDeviceDeleted(qemuMonitor *mon G_GNUC_UNUSED, virDomainObj *vm, const char *devAlias, @@ -1330,7 +1330,7 @@ qemuProcessHandleDeviceDeleted(qemuMonitor *mon G_GNUC_UNUSED, cleanup: virObjectUnlock(vm); - return 0; + return; error: qemuProcessEventFree(processEvent); goto cleanup; diff --git a/src/qemu/qemu_processpriv.h b/src/qemu/qemu_processpriv.h index d0b5735054..2bc60ce103 100644 --- a/src/qemu/qemu_processpriv.h +++ b/src/qemu/qemu_processpriv.h @@ -32,9 +32,9 @@ * This header file should never be used outside unit tests. */ -int qemuProcessHandleDeviceDeleted(qemuMonitor *mon, - virDomainObj *vm, - const char *devAlias, - void *opaque); +void qemuProcessHandleDeviceDeleted(qemuMonitor *mon, + virDomainObj *vm, + const char *devAlias, + void *opaque); int qemuProcessQMPInitMonitor(qemuMonitor *mon);