summaryrefslogtreecommitdiffstats
path: root/lib/libc/net/ascii2addr.c
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>2005-12-03 07:38:35 +0000
committerbde <bde@FreeBSD.org>2005-12-03 07:38:35 +0000
commit7aaf0755d7de77c7044d1b1d0bac2dc4d57a5ead (patch)
tree1009ca5e1b2fffe19f88b347297c125a58f00e30 /lib/libc/net/ascii2addr.c
parent2e834acd9c22a16214cd4778d549130f052dee8b (diff)
downloadFreeBSD-src-7aaf0755d7de77c7044d1b1d0bac2dc4d57a5ead.zip
FreeBSD-src-7aaf0755d7de77c7044d1b1d0bac2dc4d57a5ead.tar.gz
Simplified the fix in rev.1.3. Instead of using long double for
TWO52[sx] to trick gcc into correctly converting TWO52[sx]+x to double on assignment to "double w", force a correct assignment by assigning to *(double *)&w. This is cleaner and avoids the double rounding problem on machines that evaluate double expressions in double precision. It is not necessary to convert w-TWO52[sx] to double precision on return as implied in the comment in rev.1.3, since the difference is exact.
Diffstat (limited to 'lib/libc/net/ascii2addr.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud