[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/9] qtest: Document calling conventions
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH 2/9] qtest: Document calling conventions |
Date: |
Tue, 25 Jul 2017 14:57:01 +0100 |
User-agent: |
Mutt/1.8.3 (2017-05-23) |
On Fri, Jul 21, 2017 at 03:53:19PM +0200, Markus Armbruster wrote:
> From: Eric Blake <address@hidden>
>
> We have two flavors of vararg usage in qtest; make it clear that
> qmp() has different semantics than hmp(), and let the compiler
> enforce that hmp() is used correctly. However, qmp() (and friends)
> only accept a subset of printf flags look-alikes (namely, those
> that our JSON parser understands), and what is worse, qmp("true")
> (the JSON keyword 'true') is different from qmp("%s", "true")
> (the JSON string '"true"'), so marking those as printf-like would
> produce more harm from bogus warnings than it helps (we may have
> made a mistake in previously marking qobject_from_jsonf(), but
> this patch is not addressing that).
>
> Signed-off-by: Eric Blake <address@hidden>
> Message-Id: <address@hidden>
> Signed-off-by: Markus Armbruster <address@hidden>
> ---
> tests/libqtest.h | 22 ++++++++++++++--------
> 1 file changed, 14 insertions(+), 8 deletions(-)
Reviewed-by: Stefan Hajnoczi <address@hidden>
signature.asc
Description: PGP signature
- [Qemu-devel] [PATCH 5/9] tests/libqos/usb: Clean up string interpolation into QMP input, (continued)
- [Qemu-devel] [PATCH 5/9] tests/libqos/usb: Clean up string interpolation into QMP input, Markus Armbruster, 2017/07/21
- [Qemu-devel] [PATCH 7/9] tests: Clean up wait for event, Markus Armbruster, 2017/07/21
- [Qemu-devel] [PATCH 2/9] qtest: Document calling conventions, Markus Armbruster, 2017/07/21
- [Qemu-devel] [PATCH 6/9] tests/libqos/pci: Clean up string interpolation into QMP input, Markus Armbruster, 2017/07/21
- [Qemu-devel] [PATCH 9/9] tests/libqtest: Enable compile-time format string checking, Markus Armbruster, 2017/07/21