diff options
Diffstat (limited to 'patches/pure-ftpd-1.0.21/configure_ac-snprintf-cacheable.diff')
-rw-r--r-- | patches/pure-ftpd-1.0.21/configure_ac-snprintf-cacheable.diff | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/patches/pure-ftpd-1.0.21/configure_ac-snprintf-cacheable.diff b/patches/pure-ftpd-1.0.21/configure_ac-snprintf-cacheable.diff new file mode 100644 index 000000000..022741ebc --- /dev/null +++ b/patches/pure-ftpd-1.0.21/configure_ac-snprintf-cacheable.diff @@ -0,0 +1,45 @@ +# +# Committed-By: Marc Kleine-Budde <mkl@pengutronix.de>, 2006-11-29 +# +# Error: +# +# check for snprintf is not cross aware, make it cacheable and added cross default value +# +# State: +# +# should be commited +# +Index: pure-ftpd-1.0.21/configure.ac +=================================================================== +--- pure-ftpd-1.0.21.orig/configure.ac ++++ pure-ftpd-1.0.21/configure.ac +@@ -914,7 +914,9 @@ for (;;) { + AC_MSG_RESULT(no) + ]) + +-AC_MSG_CHECKING(whether snprintf is C99 conformant) ++AC_CACHE_CHECK([whether snprintf is C99 conformant], ++ [ac_cv_conf_snprintf_type], ++[ + AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #include <stdio.h> + #ifdef STDC_HEADERS +@@ -937,13 +939,13 @@ int main(void) + (int) snprintf(buf, sizeof buf, "12345678")); + return 0; + } +-]])],[CONF_SNPRINTF_TYPE=`cat conftestval` +-],[],[]) +-AC_MSG_RESULT(done) +-if test "x$CONF_SNPRINTF_TYPE" = "x" ; then ++]])],[ac_cv_conf_snprintf_type=`cat conftestval` ++],[],[ac_cv_conf_snprintf_type=8]) ++]) ++if test "x$ac_cv_conf_snprintf_type" = "x" ; then + AC_MSG_WARN(your operating system doesn't implement snprintf) + else +- AC_DEFINE_UNQUOTED(CONF_SNPRINTF_TYPE, $CONF_SNPRINTF_TYPE, [return value of an overflowed snprintf]) ++ AC_DEFINE_UNQUOTED(CONF_SNPRINTF_TYPE, $ac_cv_conf_snprintf_type, [return value of an overflowed snprintf]) + fi + + |