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

Re: [Xen-devel] [PATCH v7 12/14] libxl_qmp: Store advertised QEMU version in libxl__ev_qmp



Anthony PERARD writes ("[PATCH v7 12/14] libxl_qmp: Store advertised QEMU 
version in libxl__ev_qmp"):
> This will be used in a later patch.

Acked-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>

> +        o = libxl__json_map_get("QMP", resp, JSON_MAP);
> +        o = libxl__json_map_get("version", o, JSON_MAP);
> +        o = libxl__json_map_get("qemu", o, JSON_MAP);
> +#define GRAB_VERSION(level) do { \
> +        ev->qemu_version.level = libxl__json_object_get_integer( \
> +            libxl__json_map_get(#level, o, JSON_INTEGER)); \
> +        } while (0)
> +        GRAB_VERSION(major);
> +        GRAB_VERSION(minor);
> +        GRAB_VERSION(micro);

Earlier I wrote:

   I would prefer the indentation to be such that the statement inside
   the macro is indented like the ones outside.

Ie like this:

  +#define GRAB_VERSION(level) do { \
  +    ev->qemu_version.level = libxl__json_object_get_integer( \
  +        libxl__json_map_get(#level, o, JSON_INTEGER)); \
  +    } while (0)
  +        GRAB_VERSION(major);

But up to you.  My ack stands either way.

Thanks,
Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.