mingw: fix error __USE_MINGW_ANSI_STDIO redefined
PATCH 1/1 mingw: fix error __USE_MINGW_ANSI_STDIO redefined
From: Marc-André Lureau <[email protected]>
Always put osdep.h first.
Signed-off-by Marc-André Lureau <[email protected]>
--- migration/dirtyrate.c | 3 ++- tests/test-bitmap.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-)
migration/dirtyrate.c +2 -1
@@ -10,8 +10,9 @@* See the COPYING file in the top-level directory. */ -#include <zlib.h> #include "qemu/osdep.h" + +#include <zlib.h> #include "qapi/error.h" #include "cpu.h" #include "qemu/config-file.h"
tests/test-bitmap.c +2 -1
@@ -8,8 +8,9 @@* Author: Peter Xu <[email protected]> */ -#include <stdlib.h> #include "qemu/osdep.h" + +#include <stdlib.h> #include "qemu/bitmap.h" #define BMAP_SIZE 1024
Signature · 1 line
2.28.0
Quoted 31 lines · On Thu, 8 Oct 2020 at 15:41, <[email protected]> wrote:
From: Marc-André Lureau <[email protected]>
Always put
osdep.hfirst.Signed-off-by Marc-André Lureau <[email protected]>--- migration/dirtyrate.c | 3 ++- tests/test-bitmap.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-)migration/dirtyrate.c +2
-1@@ -10,8 +10,9 @@* See the COPYING file in the top-level directory. */ -#include <zlib.h> #include "qemu/osdep.h" + +#include <zlib.h> #include "qapi/error.h" #include "cpu.h" #include "qemu/config-file.h" tests/test-bitmap.c +0
-0
tests/test-bitmap.c line 14
Quoted 8 lines
tests/test-bitmap.c +2
-1@@ -8,8 +8,9 @@* Author: Peter Xu <[email protected]> */ -#include <stdlib.h> #include "qemu/osdep.h" + +#include <stdlib.h> #include "qemu/bitmap.h"
osdep.h includes stdlib for you, so you can just delete this #include line entirely.
thanks
-- PMM