[libvirt] [PATCH 2/2] qemu: migration: Ignore null ptr in qemuMigrationStopNBDServer
Ján Tomko
jtomko at redhat.com
Fri Oct 31 10:05:02 UTC 2014
On 10/31/2014 09:17 AM, weiwei li wrote:
> 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.
StartNBDServer is only run when mig->nbd is present, so if it's not there we
didn't start the server or allocate the port. Are you sure this patch is
necessary?
Jan
>
> Signed-off-by: Weiwei Li <nuonuoli at tencent.com <mailto:nuonuoli at tencent.com>>
> ---
> 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)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20141031/502aa072/attachment-0001.sig>
More information about the libvir-list
mailing list