diff options
author | Joseph Myers <joseph@codesourcery.com> | 2013-11-29 16:32:49 +0000 |
---|---|---|
committer | Joseph Myers <joseph@codesourcery.com> | 2013-11-29 16:32:49 +0000 |
commit | 2a77a467b273c1a72fa204a8fcc6d22e6e20bb1c (patch) | |
tree | 6794ce10caf493365044d4bd4197c563244d1031 /math/w_exp10.c | |
parent | ea3bc4e821e20e70b093c9a33e54f99c79e0d847 (diff) | |
download | glibc-2a77a467b273c1a72fa204a8fcc6d22e6e20bb1c.tar.gz glibc-2a77a467b273c1a72fa204a8fcc6d22e6e20bb1c.tar.xz glibc-2a77a467b273c1a72fa204a8fcc6d22e6e20bb1c.zip |
Fix exp10 errno setting on underflow (bug 6787).
Diffstat (limited to 'math/w_exp10.c')
-rw-r--r-- | math/w_exp10.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/math/w_exp10.c b/math/w_exp10.c index 3db012d1f1..17823f57ef 100644 --- a/math/w_exp10.c +++ b/math/w_exp10.c @@ -28,7 +28,7 @@ double __exp10 (double x) { double z = __ieee754_exp10 (x); - if (__builtin_expect (!__finite (z), 0) + if (__builtin_expect (!__finite (z) || z == 0, 0) && __finite (x) && _LIB_VERSION != _IEEE_) /* exp10 overflow (46) if x > 0, underflow (47) if x < 0. */ return __kernel_standard (x, x, 46 + !!__signbit (x)); |