summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2007-12-19 17:06:19 +0000
committerCorinna Vinschen <corinna@vinschen.de>2007-12-19 17:06:19 +0000
commit478df8bb912080e5b1d6aa39fb8a58cddcfc6567 (patch)
tree365ff00995466fab49112da5b071df87f71abacc
parentfcd436325b687545f9447f6853cbce4d1904461b (diff)
downloadcygnal-478df8bb912080e5b1d6aa39fb8a58cddcfc6567.tar.gz
cygnal-478df8bb912080e5b1d6aa39fb8a58cddcfc6567.tar.bz2
cygnal-478df8bb912080e5b1d6aa39fb8a58cddcfc6567.zip
* libc/stdio/vfprintf.c (_VFPRINTF_R): Use correct pointer in call to
_wcsrtombs_r.
-rw-r--r--newlib/ChangeLog7
-rw-r--r--newlib/libc/stdio/vfprintf.c4
2 files changed, 8 insertions, 3 deletions
diff --git a/newlib/ChangeLog b/newlib/ChangeLog
index 45abfcf82..78ad2bef8 100644
--- a/newlib/ChangeLog
+++ b/newlib/ChangeLog
@@ -1,3 +1,8 @@
+2007-12-19 Corinna Vinschen <corinna@vinschen.de>
+
+ * libc/stdio/vfprintf.c (_VFPRINTF_R): Use correct pointer in call to
+ _wcsrtombs_r.
+
2007-11-19 Nick Clifton <nickc@redhat.com>
* libc/machine/mn10300/Makefile.am (CCASFLAGS): Add -Wa,--gdwarf-2.
@@ -21,7 +26,7 @@
* libc/sys/arm/sys/fcntl.h: New file that includes
sys/_default_fcntl.h and defines O_BINARY.
-2007-11-08 Corinna Vinschen
+2007-11-08 Corinna Vinschen <corinna@vinschen.de>
* libc/include/sys/unistd.h: Remove Cygwin definition of MAXPATHLEN.
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;
}