[PATCH 2/2] qemu: migration: Ignore null ptr in qemuMigrationStopNBDServer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



qemuMigrationCookiePtr mig->nbd may be null when MigrationCookie
do not have nbd information ,but nbd port did allocated before and
must be released here, so ignore mig->nbd null ptr and just warn.

Signed-off-by: Weiwei Li <nuonuoli@xxxxxxxxxxx>
---
 src/qemu/qemu_migration.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c
index 0ad8054..134b041 100644
--- a/src/qemu/qemu_migration.c
+++ b/src/qemu/qemu_migration.c
@@ -1584,7 +1584,7 @@ qemuMigrationStopNBDServer(virQEMUDriverPtr driver,
     qemuDomainObjPrivatePtr priv = vm->privateData;
 
     if (!mig->nbd)
-        return;
+        VIR_WARN("mig->nbd is null");
 
     if (qemuDomainObjEnterMonitorAsync(driver, vm,
                                        QEMU_ASYNC_JOB_MIGRATION_IN) < 0)
-- 
1.7.1
--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]