diff options
Diffstat (limited to 'newlib/libc/stdio/vfprintf.c')
-rw-r--r-- | newlib/libc/stdio/vfprintf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/newlib/libc/stdio/vfprintf.c b/newlib/libc/stdio/vfprintf.c index 6746e9ede..e9c7c9e1a 100644 --- a/newlib/libc/stdio/vfprintf.c +++ b/newlib/libc/stdio/vfprintf.c @@ -1095,8 +1095,8 @@ reswitch: switch (ch) { /* Convert widechar string to multibyte string. */ memset ((_PTR)&ps, '\0', sizeof (mbstate_t)); - if (_wcsrtombs_r (data, malloc_buf, - &wcp, size, &ps) != size) { + if (_wcsrtombs_r (data, cp, &wcp, size, &ps) + != size) { fp->_flags |= __SERR; goto error; } |