diff options
| author | David Schultz <das@FreeBSD.org> | 2003-03-14 04:48:09 +0000 |
|---|---|---|
| committer | David Schultz <das@FreeBSD.org> | 2003-03-14 04:48:09 +0000 |
| commit | 3ba6b6dd9dcba1668e44f5a0bc4212f1cbf3a696 (patch) | |
| tree | f0e2b49cb1890aad41f8d58d8b149e1297d21b82 /lib/libc/stdio/vfprintf.c | |
| parent | 15a66d27983b7c66af8610073af27c15a79aa7e2 (diff) | |
Notes
Diffstat (limited to 'lib/libc/stdio/vfprintf.c')
| -rw-r--r-- | lib/libc/stdio/vfprintf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/stdio/vfprintf.c b/lib/libc/stdio/vfprintf.c index 460d4163b55a..5ade7fe5c9a2 100644 --- a/lib/libc/stdio/vfprintf.c +++ b/lib/libc/stdio/vfprintf.c @@ -1536,7 +1536,7 @@ cvt(double value, int ndigits, int flags, char *sign, int *decpt, /* print trailing zeros */ bp = digits + ndigits; if (ch == 'f') { - if (*digits == '0' && value) + if ((*digits == '0' || *digits == '\0') && value) *decpt = -ndigits + 1; bp += *decpt; } |
