qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mingw: fix error __USE_MINGW_ANSI_STDIO redefined
@ 2020-10-08 14:39 marcandre.lureau
  2020-10-08 14:43 ` Peter Maydell
  0 siblings, 1 reply; 2+ messages in thread
From: marcandre.lureau @ 2020-10-08 14:39 UTC (permalink / raw)
  To: qemu-devel; +Cc: sw, armbru, Marc-André Lureau

From: Marc-André Lureau <marcandre.lureau@redhat.com>

Always put osdep.h first.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
 migration/dirtyrate.c | 3 ++-
 tests/test-bitmap.c   | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/migration/dirtyrate.c b/migration/dirtyrate.c
index 68577ef250..47f761e67a 100644
--- a/migration/dirtyrate.c
+++ b/migration/dirtyrate.c
@@ -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"
diff --git a/tests/test-bitmap.c b/tests/test-bitmap.c
index 2f5b71458a..0a5775fb37 100644
--- a/tests/test-bitmap.c
+++ b/tests/test-bitmap.c
@@ -8,8 +8,9 @@
  * Author: Peter Xu <peterx@redhat.com>
  */
 
-#include <stdlib.h>
 #include "qemu/osdep.h"
+
+#include <stdlib.h>
 #include "qemu/bitmap.h"
 
 #define BMAP_SIZE  1024
-- 
2.28.0



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] mingw: fix error __USE_MINGW_ANSI_STDIO redefined
  2020-10-08 14:39 [PATCH] mingw: fix error __USE_MINGW_ANSI_STDIO redefined marcandre.lureau
@ 2020-10-08 14:43 ` Peter Maydell
  0 siblings, 0 replies; 2+ messages in thread
From: Peter Maydell @ 2020-10-08 14:43 UTC (permalink / raw)
  To: Marc-André Lureau; +Cc: Stefan Weil, QEMU Developers, Markus Armbruster

On Thu, 8 Oct 2020 at 15:41, <marcandre.lureau@redhat.com> wrote:
>
> From: Marc-André Lureau <marcandre.lureau@redhat.com>
>
> Always put osdep.h first.
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> ---
>  migration/dirtyrate.c | 3 ++-
>  tests/test-bitmap.c   | 3 ++-
>  2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/migration/dirtyrate.c b/migration/dirtyrate.c
> index 68577ef250..47f761e67a 100644
> --- a/migration/dirtyrate.c
> +++ b/migration/dirtyrate.c
> @@ -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"
> diff --git a/tests/test-bitmap.c b/tests/test-bitmap.c
> index 2f5b71458a..0a5775fb37 100644
> --- a/tests/test-bitmap.c
> +++ b/tests/test-bitmap.c
> @@ -8,8 +8,9 @@
>   * Author: Peter Xu <peterx@redhat.com>
>   */
>
> -#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


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-10-08 14:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-08 14:39 [PATCH] mingw: fix error __USE_MINGW_ANSI_STDIO redefined marcandre.lureau
2020-10-08 14:43 ` 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).