From 0f7bc58e529150e80f2b80262f9af1a5ebd7132e Mon Sep 17 00:00:00 2001 From: jjohnstn Date: Mon, 24 Nov 2003 18:39:04 +0000 Subject: [PATCH] 2003-11-24 Artem B. Bityuckiy * libc/stdio/vfprintf.c (_VFPRINTF_R): Fix check for 'C' format specifier to use ch instead of *fmt. --- newlib/ChangeLog | 5 +++++ newlib/libc/stdio/vfprintf.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/newlib/ChangeLog b/newlib/ChangeLog index b0cd71d66f..f9939c35a3 100644 --- a/newlib/ChangeLog +++ b/newlib/ChangeLog @@ -1,3 +1,8 @@ +2003-11-24 Artem B. Bityuckiy + + * libc/stdio/vfprintf.c (_VFPRINTF_R): Fix check for 'C' format + specifier to use ch instead of *fmt. + 2003-11-21 Artem B. Bityuckiy * libc/stdio/vfprintf.c (_VFPRINTF_R, get_arg): Move mb-specific diff --git a/newlib/libc/stdio/vfprintf.c b/newlib/libc/stdio/vfprintf.c index 62989fdb27..743d307a80 100644 --- a/newlib/libc/stdio/vfprintf.c +++ b/newlib/libc/stdio/vfprintf.c @@ -746,7 +746,7 @@ reswitch: switch (ch) { case 'c': case 'C': cp = buf; - if (*fmt == 'C' || (flags & LONGINT)) { + if (ch == 'C' || (flags & LONGINT)) { mbstate_t ps; memset((void *)&ps, '\0', sizeof(mbstate_t)); -- 2.11.0