Re: [PATCH] qemu: Don't try to parse -help for new QEMU

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 12, 2014 at 18:37:15 +0100, Peter Krempa wrote:
> On 11/12/14 17:09, Jiri Denemark wrote:
> > Since QEMU 1.2.0, we switched to QMP probing instead of parsing -help
> > (and other commands, such as -cpu ?) output. However, if QMP probing
> > failed, we still tried starting QEMU with various options and parsing
> > the output, which was guaranteed to fail because the output changed.
> > Let's just refuse parsing -help for QEMU >= 1.2.0.
> > 
> > https://bugzilla.redhat.com/show_bug.cgi?id=1160318
> > Signed-off-by: Jiri Denemark <jdenemar@xxxxxxxxxx>
> > ---
> >  src/qemu/qemu_capabilities.c | 10 ++++++++++
> >  1 file changed, 10 insertions(+)
> > 
> > diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
> > index 74a3b24..bef96d5 100644
> > --- a/src/qemu/qemu_capabilities.c
> > +++ b/src/qemu/qemu_capabilities.c
> > @@ -1384,6 +1384,16 @@ int virQEMUCapsParseHelpStr(const char *qemu,
> >  
> >      *version = (major * 1000 * 1000) + (minor * 1000) + micro;
> >  
> > +    /* Refuse to parse -help output for QEMU releases >= 1.2.0 that should be
> > +     * using QMP probing.
> > +     */
> > +    if (*version > 1002000) {

Unfortunately, this should have been >= and fixing that requires some
changes to the test suite. I'll send a v2 for additional review.

Jirka

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]