glib/gprintf.c Don't define _GNU_SOURCE on Windows, as _GNU_SOURCE has
authorTor Lillqvist <tml@novell.com>
Tue, 30 Sep 2008 14:04:35 +0000 (14:04 +0000)
committerTor Lillqvist <tml@src.gnome.org>
Tue, 30 Sep 2008 14:04:35 +0000 (14:04 +0000)
2008-09-30  Tor Lillqvist  <tml@novell.com>

* glib/gprintf.c
* glib/gnulib/vasnprintf.c: Don't define _GNU_SOURCE on Windows,
as _GNU_SOURCE has unintended side effects when compiling against
newest mingw headers.

svn path=/trunk/; revision=7563

ChangeLog
glib/gnulib/vasnprintf.c
glib/gprintf.c

index 8bc0b010439d0d0329e3b0f948367264a7e3f865..22698262c6bea8e20d9adbc30358641f60ef8508 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2008-09-30  Tor Lillqvist  <tml@novell.com>
+
+       * glib/gprintf.c
+       * glib/gnulib/vasnprintf.c: Don't define _GNU_SOURCE on Windows,
+       as _GNU_SOURCE has unintended side effects when compiling against
+       newest mingw headers.
+
 2008-09-26  Dan Winship  <danw@gnome.org>
 
        Bug 553447 – g_assert_no_error()
index c31075f686b2478d4df8fc2dcd44472c4f5294f9..a8e9cc02f1fe8ade3b27231ee8be9b03b4f6b1f3 100644 (file)
    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
    USA.  */
 
+#ifndef _WIN32
 /* Tell glibc's <stdio.h> to provide a prototype for snprintf().
    This must come before <config.h> because <config.h> may include
    <features.h>, and once <features.h> has been included, it's too late.  */
 #ifndef _GNU_SOURCE
 # define _GNU_SOURCE    1
 #endif
+#endif
 
 #ifdef HAVE_CONFIG_H
 # include <config.h>
index 6cbb214d5f509fbcc9e8363f69b9a63cf1a89a6a..35288617dff5d0d1d17f09ea2441cfa9f84075ce 100644 (file)
@@ -19,7 +19,9 @@
 
 #include "config.h"
 
+#ifndef _WIN32
 #define _GNU_SOURCE            /* For vasprintf */
+#endif
 
 #include <stdarg.h>
 #include <stdlib.h>