From 02b364e186d487f54ed410c01af042f23e812d42 Mon Sep 17 00:00:00 2001 From: Peter Krempa Date: Wed, 25 Jun 2014 18:11:17 +0200 Subject: [PATCH] qemu: blockcopy: Don't remove existing disk mirror info When creating a new disk mirror the new struct is stored in a separate variable until everything went well. The removed hunk would actually remove existing mirror information for example when the api would be run if a mirror still exists. --- src/qemu/qemu_driver.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 775dc4eb7..d34da6f5b 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -15410,10 +15410,6 @@ qemuDomainBlockCopy(virDomainObjPtr vm, endjob: if (need_unlink && unlink(dest)) VIR_WARN("unable to unlink just-created %s", dest); - if (ret < 0 && disk) { - virStorageSourceFree(disk->mirror); - disk->mirror = NULL; - } virStorageSourceFree(mirror); if (!qemuDomainObjEndJob(driver, vm)) vm = NULL; -- 2.39.5