aboutsummaryrefslogtreecommitdiff
path: root/stdio-common/vfprintf.c
diff options
context:
space:
mode:
Diffstat (limited to 'stdio-common/vfprintf.c')
-rw-r--r--stdio-common/vfprintf.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/stdio-common/vfprintf.c b/stdio-common/vfprintf.c
index 780ac76c0d..d45e7d96fc 100644
--- a/stdio-common/vfprintf.c
+++ b/stdio-common/vfprintf.c
@@ -1109,8 +1109,8 @@ vfprintf (FILE *s, const CHAR_T *format, va_list ap)
if (prec > 0) \
{ \
/* The string `s2' might not be NUL terminated. */ \
- string = (char *) alloca (prec + 1); \
- len = __wcsrtombs (string, &s2, prec + 1, &mbstate); \
+ string = (char *) alloca (prec); \
+ len = __wcsrtombs (string, &s2, prec, &mbstate); \
} \
else \
{ \