Disable win32 snprintf workaround

This is not needed with gcc 4.x.
pull/2/head
Stelios Bounanos 2009-11-27 11:21:29 +00:00
rodzic 2962ede655
commit 78d5e4dfbb
3 zmienionych plików z 8 dodań i 6 usunięć

Wyświetl plik

@ -4,12 +4,6 @@ AC_DEFUN([AC_FLDIGI_NP_COMPAT], [
AM_CONDITIONAL([COMPAT_REGEX], [test "x$ac_cv_header_regex_h" != "xyes"])
if test "x$target_mingw32" = "xyes"; then
AC_DEFINE([SNPRINTF_RETURNS_BOGUS], 1, [Defined if snprintf returns -1 when out of buffer space])
else
AC_DEFINE([SNPRINTF_RETURNS_BOGUS], 0, [Defined if snprintf returns -1 when out of buffer space])
fi
if test "x$target_mingw32" = "xyes"; then
sem_libs="pthreadGC2"
else

Wyświetl plik

@ -36,6 +36,7 @@ unsigned int _CRT_fmode = _O_BINARY;
/******************************************************************************/
#if SNPRINTF_RETURNS_BOGUS
/*
* The size parameter specifies the available space, i.e. includes
* the trailing NUL byte; but Windows's vsnprintf expects the
@ -88,6 +89,7 @@ int git_snprintf(char *str, size_t maxsize, const char *format, ...)
return ret;
}
#endif /* SNPRINTF_RETURNS_BOGUS */
unsigned sleep(unsigned seconds)
{

Wyświetl plik

@ -37,6 +37,12 @@
extern "C" {
#endif
#if defined(__WOE32__) && (!defined(__GNUC__) || __GNUC__ < 4)
# define SNPRINTF_RETURNS_BOGUS 1
#else
# define SNPRINTF_RETURNS_BOGUS 0
#endif
#if SNPRINTF_RETURNS_BOGUS
#define snprintf git_snprintf
extern int git_snprintf(char *str, size_t maxsize,