qemu: Remove return value from qemuMonitorDomainResetCallback

Change the callback prototype and fix the callback registered in the
process code.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
Peter Krempa 2021-07-20 10:05:06 +02:00
parent 40950f60fc
commit 8e95b76b1a
2 changed files with 4 additions and 7 deletions

View File

@ -166,9 +166,9 @@ typedef void (*qemuMonitorDomainShutdownCallback)(qemuMonitor *mon,
virDomainObj *vm,
virTristateBool guest,
void *opaque);
typedef int (*qemuMonitorDomainResetCallback)(qemuMonitor *mon,
virDomainObj *vm,
void *opaque);
typedef void (*qemuMonitorDomainResetCallback)(qemuMonitor *mon,
virDomainObj *vm,
void *opaque);
typedef int (*qemuMonitorDomainStopCallback)(qemuMonitor *mon,
virDomainObj *vm,
void *opaque);

View File

@ -400,7 +400,7 @@ qemuProcessFindDomainDiskByAliasOrQOM(virDomainObj *vm,
}
static int
static void
qemuProcessHandleReset(qemuMonitor *mon G_GNUC_UNUSED,
virDomainObj *vm,
void *opaque)
@ -409,7 +409,6 @@ qemuProcessHandleReset(qemuMonitor *mon G_GNUC_UNUSED,
virObjectEvent *event;
qemuDomainObjPrivate *priv;
g_autoptr(virQEMUDriverConfig) cfg = virQEMUDriverGetConfig(driver);
int ret = -1;
virObjectLock(vm);
@ -441,11 +440,9 @@ qemuProcessHandleReset(qemuMonitor *mon G_GNUC_UNUSED,
qemuDomainObjEndJob(driver, vm);
}
ret = 0;
cleanup:
virObjectUnlock(vm);
virObjectEventStateQueue(driver->domainEventState, event);
return ret;
}