diff options
| author | Alexey Zelkin <phantom@FreeBSD.org> | 2001-12-13 21:05:27 +0000 |
|---|---|---|
| committer | Alexey Zelkin <phantom@FreeBSD.org> | 2001-12-13 21:05:27 +0000 |
| commit | 243e90d6468f4d09e6a9726f4752c1a8564d5a59 (patch) | |
| tree | 822d714db12d9b83bd409dad471afb89f5aadce4 /lib/libc/stdio/vfprintf.c | |
| parent | ebacce5e997681d9f8538f2c64b670415368d739 (diff) | |
Notes
Diffstat (limited to 'lib/libc/stdio/vfprintf.c')
| -rw-r--r-- | lib/libc/stdio/vfprintf.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/libc/stdio/vfprintf.c b/lib/libc/stdio/vfprintf.c index 8aa565ce301f..a332c20f94f7 100644 --- a/lib/libc/stdio/vfprintf.c +++ b/lib/libc/stdio/vfprintf.c @@ -221,7 +221,8 @@ __ultoa(u_long val, char *endp, int base, int octzero, char *xdigs, * If (*grp == CHAR_MAX) then no more grouping * should be performed. */ - if (needgrp && ndig == *grp && *grp != CHAR_MAX) { + if (needgrp && ndig == *grp && *grp != CHAR_MAX + && sval > 9) { *--cp = thousep; ndig = 0; /* @@ -291,7 +292,8 @@ __ujtoa(uintmax_t val, char *endp, int base, int octzero, char *xdigs, * If (*grp == CHAR_MAX) then no more grouping * should be performed. */ - if (needgrp && *grp != CHAR_MAX && ndig == *grp) { + if (needgrp && *grp != CHAR_MAX && ndig == *grp + && sval > 9) { *--cp = thousep; ndig = 0; /* |
