https://git.reactos.org/?p=reactos.git;a=commitdiff;h=38c0da9978b9e268886b1a...
commit 38c0da9978b9e268886b1a23aa9b84f4e3254c30 Author: Katayama Hirofumi MZ katayama.hirofumi.mz@gmail.com AuthorDate: Tue Feb 14 20:54:53 2023 +0900 Commit: GitHub noreply@github.com CommitDate: Tue Feb 14 20:54:53 2023 +0900
[CRT] printf/wprintf: Support %zu (#5056)
"%zu" is a printf format specifier for type size_t. Some apps assume the implementation of this specifier. CORE-17787 --- sdk/lib/crt/printf/streamout.c | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/sdk/lib/crt/printf/streamout.c b/sdk/lib/crt/printf/streamout.c index 2886ad63d13..36bc7a31182 100644 --- a/sdk/lib/crt/printf/streamout.c +++ b/sdk/lib/crt/printf/streamout.c @@ -432,6 +432,10 @@ streamout(FILE *stream, const TCHAR *format, va_list argptr) else if (chr == _T('w')) flags |= FLAG_WIDECHAR; else if (chr == _T('L')) flags |= 0; // FIXME: long double else if (chr == _T('F')) flags |= 0; // FIXME: what is that? + else if (chr == _T('z') && *format && strchr("udxXion", *format)) + { + flags |= FLAG_INTPTR; + } else if (chr == _T('l')) { /* Check if this is the 2nd 'l' in a row */