#18353 closed bug (fixed)
swprintf produces wrong output for hexadecimal floating-point numbers
Reported by: | bhaible | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | R1/beta5 |
Component: | System/POSIX | Version: | R1/beta4 |
Keywords: | r1beta4-fixes | Cc: | |
Blocked By: | Blocking: | ||
Platform: | x86-64 |
Description
Haiku r1beta4, on x86_64, produces wrong output in swprintf directives that shall print long doubles in hexadecimal format.
POSIX https://pubs.opengroup.org/onlinepubs/9699919799/functions/swprintf.html describes the 'a' directive for swprintf.
How to reproduce:
$ gcc -Wall -ggdb foo.c $ ./a.out
Expected output:
ret = 9 result=0xc.91p-2 ret = 9 result=0xc.91p-2
Actual output:
ret = 9 result=0xc.91p-2 ret = 9 result=0xc.c9p-2
Attachments (1)
Change History (6)
by , 20 months ago
comment:1 by , 20 months ago
This bug also existed in glibc 2.15. It is fixed in glibc 2.17 and newer. The fix was probably the commit a9f8e53a5b14ba481999ded036b025554ea06362 by Joseph Myers (2012-09-24).
comment:2 by , 20 months ago
Milestone: | Unscheduled → R1/beta5 |
---|---|
Platform: | All → x86-64 |
Resolution: | → fixed |
Status: | new → closed |
comment:3 by , 20 months ago
Milestone: | R1/beta5 → R1/beta4 |
---|
cherry-picked to r1beta4 too. Expect the next system update to include this.
comment:4 by , 20 months ago
Milestone: | R1/beta4 → R1/beta5 |
---|
comment:5 by , 20 months ago
Keywords: | r1beta4-fixes added |
---|
Note:
See TracTickets
for help on using tickets.
test case