]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Avoid MinGW warnings about redefinition of snprintf.
authorEli Zaretskii <eliz@gnu.org>
Sun, 17 Mar 2013 19:10:38 +0000 (19:10 +0000)
committerEli Zaretskii <eliz@gnu.org>
Sun, 17 Mar 2013 19:10:38 +0000 (19:10 +0000)
 gdb/python/python-internal.h (HAVE_SNPRINTF)
 [_WIN32 && HAVE_DECL_SNPRINTF]: Define, to avoid compiler warnings
 about redefinition of snprintf by pyerrors.h.

gdb/ChangeLog
gdb/python/python-internal.h

index da461ecb5d800fb28db7c00a23209eb06b058260..5dc439c0f2a0d6a31595df8c1c39479f0ae08263 100644 (file)
@@ -1,3 +1,9 @@
+2013-03-17  Eli Zaretskii  <eliz@gnu.org>
+
+       * python/python-internal.h (HAVE_SNPRINTF)
+       [_WIN32 && HAVE_DECL_SNPRINTF]: Define, to avoid compiler warnings
+       about redefinition of snprintf by pyerrors.h.
+
 2013-03-15  Steve Ellcey  <sellcey@mips.com>
 
        * remote-sim.c (sim_command_completer): Make char arguments const.
index 753ba96a012e88c93f66c9c4d53e5235f5dcf3ea..ea97226f473395c344dff8117f7a145e6c160e0a 100644 (file)
    around technique as above.  */
 #undef _FILE_OFFSET_BITS
 
+/* A kludge to avoid redefinition of snprintf on Windows by pyerrors.h.  */
+#if defined(_WIN32) && defined(HAVE_DECL_SNPRINTF)
+#define HAVE_SNPRINTF 1
+#endif
+
 /* Request clean size types from Python.  */
 #define PY_SSIZE_T_CLEAN