* [Qemu-devel] [PATCH] w64: Fix compiler warnings (wrong format specifier)
@ 2013-04-13 20:45 Stefan Weil
2013-04-19 9:38 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
0 siblings, 1 reply; 2+ messages in thread
From: Stefan Weil @ 2013-04-13 20:45 UTC (permalink / raw)
To: qemu-trivial; +Cc: Stefan Weil, qemu-devel
GetLastError() returns a DWORD value which is unsigned long,
so the correct format specifier is %lu.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
---
Debian's w32 cross compiler does not complain about the wrong
specifiers, but the w64 cross compiler does.
I'm sorry that I did not notice this before sending the pull
request.
cpus.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/cpus.c b/cpus.c
index 97e9ab4..3f754c6 100644
--- a/cpus.c
+++ b/cpus.c
@@ -865,7 +865,7 @@ static void qemu_cpu_kick_thread(CPUState *cpu)
CONTEXT tcgContext;
if (SuspendThread(cpu->hThread) == (DWORD)-1) {
- fprintf(stderr, "qemu:%s: GetLastError:%d\n", __func__,
+ fprintf(stderr, "qemu:%s: GetLastError:%lu\n", __func__,
GetLastError());
exit(1);
}
@@ -881,7 +881,7 @@ static void qemu_cpu_kick_thread(CPUState *cpu)
cpu_signal(0);
if (ResumeThread(cpu->hThread) == (DWORD)-1) {
- fprintf(stderr, "qemu:%s: GetLastError:%d\n", __func__,
+ fprintf(stderr, "qemu:%s: GetLastError:%lu\n", __func__,
GetLastError());
exit(1);
}
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [Qemu-trivial] [PATCH] w64: Fix compiler warnings (wrong format specifier)
2013-04-13 20:45 [Qemu-devel] [PATCH] w64: Fix compiler warnings (wrong format specifier) Stefan Weil
@ 2013-04-19 9:38 ` Stefan Hajnoczi
0 siblings, 0 replies; 2+ messages in thread
From: Stefan Hajnoczi @ 2013-04-19 9:38 UTC (permalink / raw)
To: Stefan Weil; +Cc: qemu-trivial, qemu-devel
On Sat, Apr 13, 2013 at 10:45:50PM +0200, Stefan Weil wrote:
> GetLastError() returns a DWORD value which is unsigned long,
> so the correct format specifier is %lu.
>
> Signed-off-by: Stefan Weil <sw@weilnetz.de>
> ---
>
> Debian's w32 cross compiler does not complain about the wrong
> specifiers, but the w64 cross compiler does.
>
> I'm sorry that I did not notice this before sending the pull
> request.
>
>
> cpus.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Thanks, applied to the trivial patches tree:
https://github.com/stefanha/qemu/commits/trivial-patches
Stefan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-04-19 9:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-13 20:45 [Qemu-devel] [PATCH] w64: Fix compiler warnings (wrong format specifier) Stefan Weil
2013-04-19 9:38 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
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).