* [Qemu-devel] [PATCH for-2.4] disas/arm-a64: Add missing compiler attribute GCC_FMT_ATTR
@ 2015-07-18 8:27 Stefan Weil
2015-07-18 9:13 ` Peter Maydell
0 siblings, 1 reply; 3+ messages in thread
From: Stefan Weil @ 2015-07-18 8:27 UTC (permalink / raw)
To: QEMU Trivial, Peter Maydell; +Cc: Stefan Weil, QEMU Developer
Type fprintf_function which fits here was defined with this attribute.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
---
This is an optional trivial patch for 2.4 which fixes compiler warnings
in my build environment (with -Wextra).
disas/arm-a64.cc | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/disas/arm-a64.cc b/disas/arm-a64.cc
index b0803f9..b57256b 100644
--- a/disas/arm-a64.cc
+++ b/disas/arm-a64.cc
@@ -42,7 +42,7 @@ public:
stream_ = stream;
}
- void SetPrintf(int (*printf_fn)(FILE *, const char *, ...)) {
+ void SetPrintf(fprintf_function printf_fn) {
printf_ = printf_fn;
}
@@ -53,7 +53,7 @@ protected:
}
private:
- int (*printf_)(FILE *, const char *, ...);
+ fprintf_function printf_;
FILE *stream_;
};
--
2.1.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH for-2.4] disas/arm-a64: Add missing compiler attribute GCC_FMT_ATTR
2015-07-18 8:27 [Qemu-devel] [PATCH for-2.4] disas/arm-a64: Add missing compiler attribute GCC_FMT_ATTR Stefan Weil
@ 2015-07-18 9:13 ` Peter Maydell
2015-07-20 10:47 ` Peter Maydell
0 siblings, 1 reply; 3+ messages in thread
From: Peter Maydell @ 2015-07-18 9:13 UTC (permalink / raw)
To: Stefan Weil; +Cc: QEMU Trivial, QEMU Developer
On 18 July 2015 at 09:27, Stefan Weil <sw@weilnetz.de> wrote:
> Type fprintf_function which fits here was defined with this attribute.
>
> Signed-off-by: Stefan Weil <sw@weilnetz.de>
> ---
>
> This is an optional trivial patch for 2.4 which fixes compiler warnings
> in my build environment (with -Wextra).
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
No objection if you want to put it in 2.4, though I'm a bit
surprised that missing GCC_FMT_ATTR provokes warnings.
The cleanup is nice anyway.
thanks
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH for-2.4] disas/arm-a64: Add missing compiler attribute GCC_FMT_ATTR
2015-07-18 9:13 ` Peter Maydell
@ 2015-07-20 10:47 ` Peter Maydell
0 siblings, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2015-07-20 10:47 UTC (permalink / raw)
To: Stefan Weil; +Cc: QEMU Trivial, QEMU Developer
On 18 July 2015 at 10:13, Peter Maydell <peter.maydell@linaro.org> wrote:
> On 18 July 2015 at 09:27, Stefan Weil <sw@weilnetz.de> wrote:
>> Type fprintf_function which fits here was defined with this attribute.
>>
>> Signed-off-by: Stefan Weil <sw@weilnetz.de>
>> ---
>>
>> This is an optional trivial patch for 2.4 which fixes compiler warnings
>> in my build environment (with -Wextra).
>
> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
>
> No objection if you want to put it in 2.4, though I'm a bit
> surprised that missing GCC_FMT_ATTR provokes warnings.
> The cleanup is nice anyway.
I've applied this to target-arm.next. Thanks.
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-07-20 10:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-18 8:27 [Qemu-devel] [PATCH for-2.4] disas/arm-a64: Add missing compiler attribute GCC_FMT_ATTR Stefan Weil
2015-07-18 9:13 ` Peter Maydell
2015-07-20 10:47 ` Peter Maydell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).