]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemuBuildFSStr: Properly format 'readonly' attribute
authorPeter Krempa <pkrempa@redhat.com>
Mon, 23 Mar 2026 07:50:56 +0000 (08:50 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Tue, 24 Mar 2026 16:58:42 +0000 (17:58 +0100)
Short-form booleans are deprecated in qemu since qemu 6.0. Switch to the
proper 'readonly=on' format.

Closes: https://gitlab.com/libvirt/libvirt/-/work_items/864
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/qemu/qemu_command.c

index 18f33a9d1454f2a34cef7c101dfa161782b723b2..5b7423e3541556d9055c8a9b7d7eddf3dd8d9814 100644 (file)
@@ -2478,7 +2478,7 @@ qemuBuildFSStr(virDomainFSDef *fs)
     virQEMUBuildBufferEscapeComma(&opt, fs->src->path);
 
     if (fs->readonly)
-        virBufferAddLit(&opt, ",readonly");
+        virBufferAddLit(&opt, ",readonly=on");
 
     return virBufferContentAndReset(&opt);
 }