Do you have a question? Post it now! No Registration Necessary
November 24, 2004, 7:06 am

I fond a bug in gcvt.c, becase the round-off didn't add into the
integer part, when the number is 29.997 with digit 2 will be 29.00 .
and I found that just change one number:
k = f + 0.1/scale;
f2= f - k;
to
k = f + 0.5/scale;
f2= f - k;
this bug is corrected.
* there are 2 gcvt.c files, one is in libc/math, the other is in libm
integer part, when the number is 29.997 with digit 2 will be 29.00 .
and I found that just change one number:
k = f + 0.1/scale;
f2= f - k;
to
k = f + 0.5/scale;
f2= f - k;
this bug is corrected.
* there are 2 gcvt.c files, one is in libc/math, the other is in libm
Site Timeline
- » Re-scanning PCI devices
- — Next thread in » Embedded Linux
-
- » probolem about ppc755 linux kernel booting.(waiting online...)
- — Previous thread in » Embedded Linux
-
- » Crosscompiling for ARM: reloc type R_ARM_ABS32 is not supported for PIC - ...
- — Newest thread in » Embedded Linux
-
- » Pomiar przepĹ‚ywu
- — The site's Newest Thread. Posted in » Electronics (Polish)
-
- » Communist Chinese Military Companies
- — The site's Last Updated Thread. Posted in » Embedded Programming
-