Skip to content
Snippets Groups Projects
Commit 52e3f304 authored by Pavel Hrdina's avatar Pavel Hrdina
Browse files

qemu_driver: Fix virDomainSaveImageDefineXML


Commit 28a06215 added support to restore
sparse images but changed the boolean that controls if we open the file
as read-only or read-write. Editing XML in the save image resulted in
following error message:

    failed to write header to domain save file '/data/images/fedora40.save': Bad file descriptor

Signed-off-by: default avatarPavel Hrdina <phrdina@redhat.com>
Reviewed-by: default avatarJim Fehlig <jfehlig@suse.com>
parent a442f46b
No related branches found
No related tags found
No related merge requests found
Pipeline #1734131085 passed
......@@ -5948,7 +5948,7 @@ qemuDomainSaveImageDefineXML(virConnectPtr conn, const char *path,
if (qemuSaveImageGetMetadata(driver, NULL, path, &def, &data) < 0)
goto cleanup;
 
fd = qemuSaveImageOpen(driver, path, false, false, NULL, false);
fd = qemuSaveImageOpen(driver, path, false, false, NULL, true);
 
if (fd < 0)
goto cleanup;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment