summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2013-08-05 18:13:20 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2013-08-05 18:13:20 +0000
commitc769d1a992247045cf7682bfc1dbbe6221bc383a (patch)
tree5940b126382a2946795f62dfd8515e813dbd5b1a /lib
parent53c3e8d1cde2923838604ff4d5444403f692f129 (diff)
tgamma(+-0) == +-Inf
ok martynas@
Diffstat (limited to 'lib')
-rw-r--r--lib/libm/src/ld80/e_tgammal.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/libm/src/ld80/e_tgammal.c b/lib/libm/src/ld80/e_tgammal.c
index 3d1352efe3c..fc710bf6957 100644
--- a/lib/libm/src/ld80/e_tgammal.c
+++ b/lib/libm/src/ld80/e_tgammal.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: e_tgammal.c,v 1.2 2011/07/20 21:02:51 martynas Exp $ */
+/* $OpenBSD: e_tgammal.c,v 1.3 2013/08/05 18:13:19 kettenis Exp $ */
/*
* Copyright (c) 2008 Stephen L. Moshier <steve@moshier.net>
@@ -229,6 +229,8 @@ if(x == INFINITY)
return(INFINITY);
if(x == -INFINITY)
return(x - x);
+if( x == 0.0L )
+ return( 1.0L / x );
q = fabsl(x);
if( q > 13.0L )