Jelajahi Sumber

* Fixed strftime() compile warning

svn: 631
Bryan Drewery 22 tahun lalu
induk
melakukan
61de9a5502
2 mengubah file dengan 7 tambahan dan 1 penghapusan
  1. 5 0
      src/compat/strftime.c
  2. 2 1
      src/compat/strftime.h

+ 5 - 0
src/compat/strftime.c

@@ -13,4 +13,9 @@
 #  define strftime	egg_strftime
 
 #  include "gnu_strftime.c"
+#else /* HAVE_STRFTIME */
+
+size_t my_strftime(char *s, size_t max, const char *fmt, const struct tm *tm) {
+  return strftime(s, max, fmt, tm);
+}
 #endif	/* !HAVE_STRFTIME */

+ 2 - 1
src/compat/strftime.h

@@ -17,7 +17,8 @@
 size_t egg_strftime(char *s, size_t maxsize, const char *format,
 		    const struct tm *tp);
 #else
-#  define egg_strftime	strftime
+#  define egg_strftime	my_strftime
+size_t my_strftime(char *, size_t, const char *, const struct tm *);
 #endif
 
 #endif	/* !_EGG_COMPAT_STRFTIME_H_ */