summaryrefslogtreecommitdiff
path: root/m4/vsnprintf.m4
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2010-12-23 23:32:55 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2010-12-23 23:33:30 -0800
commit562547d19b88ca771061280e43c4c97143e43463 (patch)
tree4addc54fe81d0f9788948813dbb4eb6863fbe235 /m4/vsnprintf.m4
parentedfd5f9af764c1b43b948171e767e181125cfe09 (diff)
downloadgnulib-562547d19b88ca771061280e43c4c97143e43463.tar.gz
vsnprintf: make more consistent with snprintf; doc fixes
* doc/posix-functions/snprintf.texi (snprintf): The workaround for the byte count return problem was promoted from the snprintf-posix to the snprintf module. * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise. * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Also check gl_SNPRINTF_RETVAL_C99, for consistency with gl_FUNC_SNPRINTF. * tests/test-snprintf.c (main): Check the byte count returned. * tests/test-vsnprintf.c (main): Likewise.
Diffstat (limited to 'm4/vsnprintf.m4')
-rw-r--r--m4/vsnprintf.m47
1 files changed, 6 insertions, 1 deletions
diff --git a/m4/vsnprintf.m4 b/m4/vsnprintf.m4
index ed189c2388..17109a7a2e 100644
--- a/m4/vsnprintf.m4
+++ b/m4/vsnprintf.m4
@@ -13,7 +13,12 @@ AC_DEFUN([gl_FUNC_VSNPRINTF],
gl_SNPRINTF_SIZE1
case "$gl_cv_func_snprintf_size1" in
*yes)
- gl_cv_func_vsnprintf_usable=yes
+ gl_SNPRINTF_RETVAL_C99
+ case "$gl_cv_func_snprintf_retval_c99" in
+ *yes)
+ gl_cv_func_vsnprintf_usable=yes
+ ;;
+ esac
;;
esac
fi