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.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/stdio-common/vfprintf.c b/stdio-common/vfprintf.c
index ef9e62f..d97476b 100644
--- a/stdio-common/vfprintf.c
+++ b/stdio-common/vfprintf.c
@@ -1499,8 +1499,7 @@ group_number (CHAR_T *w, CHAR_T *rear_ptr, const CHAR_T *grouping,
/* Copy existing string so that nothing gets overwritten. */
src = (char *) alloca (rear_ptr - w);
- memcpy (src, w + 1, rear_ptr - w);
- s = &src[rear_ptr - w - 1];
+ s = (char *) __mempcpy (src, w + 1, rear_ptr - w) - 1;
w = rear_ptr;
/* Process all characters in the string. */