Signed-off-by: Ján Tomko <jtomko(a)redhat.com>
---
src/qemu/qemu_tpm.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/qemu/qemu_tpm.c b/src/qemu/qemu_tpm.c
index 21792f6992..6741373583 100644
--- a/src/qemu/qemu_tpm.c
+++ b/src/qemu/qemu_tpm.c
@@ -865,19 +865,18 @@ qemuExtTPMStart(virQEMUDriverPtr driver,
virDomainObjPtr vm,
bool incomingMigration)
{
- int ret = 0;
virDomainTPMDefPtr tpm = vm->def->tpm;
switch (tpm->type) {
case VIR_DOMAIN_TPM_TYPE_EMULATOR:
- ret = qemuExtTPMStartEmulator(driver, vm, incomingMigration);
- break;
+ return qemuExtTPMStartEmulator(driver, vm, incomingMigration);
+
case VIR_DOMAIN_TPM_TYPE_PASSTHROUGH:
case VIR_DOMAIN_TPM_TYPE_LAST:
break;
}
- return ret;
+ return 0;
}
--
2.21.0