summaryrefslogtreecommitdiff
path: root/msdos
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2014-08-23 11:22:46 +0300
committerEli Zaretskii <eliz@gnu.org>2014-08-23 11:22:46 +0300
commit934cde5459b50b54901c1583e7d19ff0dd5dd6ab (patch)
treec2035304ac6f4e9eff3f63d03379e82979849280 /msdos
parent09f3715543c655375e4b0b9cfab00b42b6a4ff0d (diff)
downloademacs-934cde5459b50b54901c1583e7d19ff0dd5dd6ab.tar.gz
Fix compilation warnings about snprintf in the MSDOS build.
msdos/sed2v2.inp [DJGPP <= 2.03]: Add a prototype for snprintf, to avoid compilation warning from newer GCC versions that have snprintf as a built-in. Reported by Juan Manuel Guerrero <juan.guerrero@gmx.de>.
Diffstat (limited to 'msdos')
-rw-r--r--msdos/ChangeLog7
-rw-r--r--msdos/sed2v2.inp2
2 files changed, 9 insertions, 0 deletions
diff --git a/msdos/ChangeLog b/msdos/ChangeLog
index f1d6c322bc2..c40d7295cbd 100644
--- a/msdos/ChangeLog
+++ b/msdos/ChangeLog
@@ -1,3 +1,10 @@
+2014-08-23 Eli Zaretskii <eliz@gnu.org>
+
+ * sed2v2.inp [DJGPP <= 2.03]: Add a prototype for snprintf, to
+ avoid compilation warning from newer GCC versions that have
+ snprintf as a built-in. Reported by Juan Manuel Guerrero
+ <juan.guerrero@gmx.de>.
+
2014-04-16 Eli Zaretskii <eliz@gnu.org>
* sedlisp.inp:
diff --git a/msdos/sed2v2.inp b/msdos/sed2v2.inp
index d5211fdfdbf..ed14b12ca24 100644
--- a/msdos/sed2v2.inp
+++ b/msdos/sed2v2.inp
@@ -131,6 +131,8 @@ s/^#undef HAVE_STRTOULL *$/#define HAVE_STRTOULL 1/
#define HAVE_SNPRINTF 1\
#else\
#undef HAVE_SNPRINTF\
+#include <sys/types.h>\
+extern int snprintf (char *__restrict, size_t, const char *__restrict, ...);\
#endif
s/^#undef PENDING_OUTPUT_N_BYTES *$/#define PENDING_OUTPUT_N_BYTES fp->_ptr - fp->_base/