For unsigned print formats like %u, %o and %x, don't print a leading plus. It wasn't printed for %+o and %+x, but %+u did print one.
Signed-off-by: Martin Storsjö <mar...@martin.st> --- mingw-w64-crt/stdio/mingw_pformat.c | 1 + 1 file changed, 1 insertion(+) diff --git a/mingw-w64-crt/stdio/mingw_pformat.c b/mingw-w64-crt/stdio/mingw_pformat.c index a68d0f67a..b1c139bbe 100644 --- a/mingw-w64-crt/stdio/mingw_pformat.c +++ b/mingw-w64-crt/stdio/mingw_pformat.c @@ -2492,6 +2492,7 @@ __pformat (int flags, void *dest, int max, const APICHAR *fmt, va_list argv) /* * Unsigned integer values; octal, decimal or hexadecimal format... */ + stream.flags &= ~PFORMAT_POSITIVE; #if __ENABLE_PRINTF128 argval.__pformat_u128_t.t128.digits[1] = 0LL; /* no sign extend needed */ if( length == PFORMAT_LENGTH_LLONG128 ) -- 2.25.1 _______________________________________________ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public