]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Win32: Fix compilation warnings triggered by Python's pyerrors.h
authorJoel Brobecker <brobecker@gnat.com>
Tue, 19 Mar 2013 21:13:32 +0000 (21:13 +0000)
committerJoel Brobecker <brobecker@gnat.com>
Tue, 19 Mar 2013 21:13:32 +0000 (21:13 +0000)
gdb/ChangeLog:

        * 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 7c02381af5bc4e9b4b3a100e23cc3ebfcc011a69..d14a13e1d19738848d2445095a2ebfe8c5078b26 100644 (file)
@@ -8,6 +8,12 @@
        * elfread.c (elf_symtab_read): Handle BSF_GNU_UNIQUE for certain
        symbols.
 
+2013-03-19  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-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        * source.c (print_source_lines_base): Make a local copy of
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