[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
This commit is contained in:
Katayama Hirofumi MZ 2023-02-14 20:54:53 +09:00 committed by GitHub
parent 324cda0835
commit 38c0da9978
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -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 */