aboutsummaryrefslogtreecommitdiff
path: root/math/auto-libm-test-in
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2014-03-31 14:56:37 +0000
committerJoseph Myers <joseph@codesourcery.com>2014-03-31 14:56:37 +0000
commit54fa2475d37b9c7afd903eb970362e50ec76f01e (patch)
tree7edfc5402ad7ae934fb27a9b132aaa7950d92262 /math/auto-libm-test-in
parent757d9dd5c3efa56fac75965abc014faaae7b7895 (diff)
downloadglibc-54fa2475d37b9c7afd903eb970362e50ec76f01e.tar
glibc-54fa2475d37b9c7afd903eb970362e50ec76f01e.tar.gz
glibc-54fa2475d37b9c7afd903eb970362e50ec76f01e.tar.bz2
glibc-54fa2475d37b9c7afd903eb970362e50ec76f01e.zip
Set errno for atan2 underflow (bug 16349).
This patch fixes bug 16349, missing errno setting for atan2 underflow, by adding appropriate checks to the existing wrappers. (As in other cases, the __kernel_standard support for calling matherr is considered to be for existing code expecting existing rules for what's considered an error, even if those don't correspond to a general logical scheme for what counts as what kind of error, so __set_errno calls are added directly without any changes to __kernel_standard.) Tested x86_64 and x86. [BZ #16349] * math/w_atan2.c: Include <errno.h>. (__atan2): Set errno for result underflowing to zero. * math/w_atan2f.c: Include <errno.h>. (__atan2f): Set errno for result underflowing to zero. * math/w_atan2l.c: Include <errno.h>. (__atan2l): Set errno for result underflowing to zero. * math/auto-libm-test-in: Don't allow missing errno for some atan2 tests. * math/auto-libm-test-out: Regenerated.
Diffstat (limited to 'math/auto-libm-test-in')
-rw-r--r--math/auto-libm-test-in9
1 files changed, 4 insertions, 5 deletions
diff --git a/math/auto-libm-test-in b/math/auto-libm-test-in
index 7ad407c238..420f657d81 100644
--- a/math/auto-libm-test-in
+++ b/math/auto-libm-test-in
@@ -157,13 +157,12 @@ atan2 -min -max
atan2 min_subnorm -max
atan2 -min_subnorm -max
# Bug 15319: underflow exception may be missing.
-# Bug 16349: errno setting may be missing.
atan2 1 max missing-underflow
atan2 -1 max missing-underflow
-atan2 min max missing-underflow missing-errno
-atan2 -min max missing-underflow missing-errno
-atan2 min_subnorm max missing-underflow missing-errno
-atan2 -min_subnorm max missing-underflow missing-errno
+atan2 min max missing-underflow
+atan2 -min max missing-underflow
+atan2 min_subnorm max missing-underflow
+atan2 -min_subnorm max missing-underflow
atanh 0
atanh -0