On Tuesday 17 May 2016 15:45:42 Richard W.M. Jones wrote:
> On Tue, May 17, 2016 at 03:41:10PM +0200, Pino Toscano wrote:
> > +extern bool guestfs_int_version_is (const struct version *v, int maj, int 
> > min, int mic);
> 
> I think calling this function "is" is a bit misleading.  I think
> we should have _ge and _le functions (cf my patch).

Makes sense, renamed to _ge.

> This comparison for example is wrong:
> 
> >    /* qemu 1.1 claims to support virtio-scsi but in reality it's broken. */
> > -  if (data->qemu_version_major == 1 && data->qemu_version_minor < 2)
> > +  if (!guestfs_int_version_is (&data->qemu_version, 1, 2, 0))
> >      return 1;

The older code was basically checking for versions in the interval
[1, 2[, while the change turns that into a [0, 2[.  Considering the
qemu version supported is >= 1.0 anyway, the final effect is the same.
Am I missing anything?

Thanks,
-- 
Pino Toscano

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Libguestfs mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/libguestfs

Reply via email to