summaryrefslogtreecommitdiff
path: root/sysdeps/ieee754/ldbl-128/s_log1pl.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/ieee754/ldbl-128/s_log1pl.c')
-rw-r--r--sysdeps/ieee754/ldbl-128/s_log1pl.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c
index d8d89f0a8c..4a30af62fa 100644
--- a/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c
@@ -144,7 +144,10 @@ __log1pl (long double xm1)
return xm1;
}
- x = xm1 + 1.0L;
+ if (xm1 >= 0x1p113L)
+ x = xm1;
+ else
+ x = xm1 + 1.0L;
/* log1p(-1) = -inf */
if (x <= 0.0L)