On Thu, Aug 09, 2018 at 02:48:59PM +0200, Peter Krempa wrote:
Starting from pc-q35-2.4 the floppy controller is not enabled by default. Fix the version check so that it does not match 2.11 as being 2.1.
O:-) Thanks.
Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx> --- src/qemu/qemu_domain.c | 12 ++++++++---- .../qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args | 4 +--- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index a5d81f863b..654cd4b872 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -9427,10 +9427,14 @@ qemuDomainMachineNeedsFDC(const char *machine) if (p) { if (STRPREFIX(p, "1.") || - STRPREFIX(p, "2.0") || - STRPREFIX(p, "2.1") || - STRPREFIX(p, "2.2") || - STRPREFIX(p, "2.3")) + STREQ(p, "2.0") || + STRPREFIX(p, "2.0-") || + STREQ(p, "2.1") || + STRPREFIX(p, "2.1-") || + STREQ(p, "2.2") || + STRPREFIX(p, "2.2-") || + STREQ(p, "2.3") || + STRPREFIX(p, "2.3-"))
I think STREQs are just enough here - unless you know of any downstreams adding something after the QEMU version after a dash. Reviewed-by: Ján Tomko <jtomko@xxxxxxxxxx> Jano
Attachment:
signature.asc
Description: Digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list