summaryrefslogtreecommitdiff
path: root/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
diff options
context:
space:
mode:
Diffstat (limited to 'libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c')
-rw-r--r--libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
index b9302974c..d08044847 100644
--- a/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
@@ -772,6 +772,12 @@ __ieee754_lgammal_r (x, signgamp)
if (! __finitel (x))
return x * x;
+ if (x == 0.0L)
+ {
+ if (__signbitl (x))
+ *signgamp = -1;
+ }
+
if (x < 0.0L)
{
q = -x;