diff options
Diffstat (limited to 'sysdeps/ieee754/ldbl-128/e_j1l.c')
-rw-r--r-- | sysdeps/ieee754/ldbl-128/e_j1l.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/sysdeps/ieee754/ldbl-128/e_j1l.c b/sysdeps/ieee754/ldbl-128/e_j1l.c index 1264c95d49..f24dfa9f8b 100644 --- a/sysdeps/ieee754/ldbl-128/e_j1l.c +++ b/sysdeps/ieee754/ldbl-128/e_j1l.c @@ -95,6 +95,7 @@ License along with this library; if not, see <http://www.gnu.org/licenses/>. */ +#include <errno.h> #include <math.h> #include <math_private.h> #include <float.h> @@ -852,7 +853,12 @@ __ieee754_y1l (long double x) } xx = fabsl (x); if (xx <= 0x1p-114) - return -TWOOPI / x; + { + z = -TWOOPI / x; + if (__isinfl (z)) + __set_errno (ERANGE); + return z; + } if (xx <= 2.0L) { /* 0 <= x <= 2 */ |