From b85c06ba36da589ef74b0e9ecb129627b5c06fc7 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Mon, 15 Feb 2010 16:10:28 +0000 Subject: * libc/stdio/vfprintf.c (_VFPRINTF_R): Drop printing a redundant decimal point in case the float argument is an integral value. --- newlib/libc/stdio/vfprintf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'newlib/libc/stdio/vfprintf.c') diff --git a/newlib/libc/stdio/vfprintf.c b/newlib/libc/stdio/vfprintf.c index be4170cc2..be35d248c 100644 --- a/newlib/libc/stdio/vfprintf.c +++ b/newlib/libc/stdio/vfprintf.c @@ -1578,7 +1578,7 @@ number: if ((dprec = prec) >= 0) cp = convbuf + ndig; } #endif - if (prec || flags & ALT) + if (expt < ndig || flags & ALT) PRINT (decimal_point, decp_len); PRINTANDPAD (cp, convbuf + ndig, ndig - expt, zeroes); -- cgit v1.2.3