"getCompressionType" trys to throw error when invalid dump image format is specified, or the compression program for the specified image format is not available, but at the same time, it returns enum qemud_save_formats, as a result, upper function will think it was successful, and disgard to check the error.
Change "qemuReportError" into "VIR_WARN" instead to let the user known what happened. v1 patch is here: http://www.redhat.com/archives/libvir-list/2011-January/msg00715.html As it reverted b6f13bb7002da76db15242e1d996e8a6222a754, and it was intentionally to chose the behavior of falling back to raw if the compression type is invalid, so simply use "VIR_WARN" to fix the problem. * src/qemu/qemu_driver.c --- src/qemu/qemu_driver.c | 13 ++++++------- 1 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 34cc29f..dac71fa 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -4806,16 +4806,15 @@ getCompressionType(struct qemud_driver *driver) if (driver->dumpImageFormat) { compress = qemudSaveCompressionTypeFromString(driver->dumpImageFormat); if (compress < 0) { - qemuReportError(VIR_ERR_OPERATION_FAILED, "%s", - _("Invalid dump image format specified in " - "configuration file, using raw")); + VIR_WARN("Invalid dump image format '%s' specified in " + "configuration file, using raw", + driver->dumpImageFormat); return QEMUD_SAVE_FORMAT_RAW; } if (!qemudCompressProgramAvailable(compress)) { - qemuReportError(VIR_ERR_OPERATION_FAILED, - "%s", _("Compression program for dump image format " - "in configuration file isn't available, " - "using raw")); + VIR_WARN("Compression program for dump image format '%s' " + "in configuration file isn't available, using raw", + driver->dumpImageFormat); return QEMUD_SAVE_FORMAT_RAW; } } -- 1.7.3.2 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list