summaryrefslogtreecommitdiff
path: root/tanh.c
diff options
context:
space:
mode:
Diffstat (limited to 'tanh.c')
-rw-r--r--tanh.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tanh.c b/tanh.c
index f2d05ec82..9ff5420f7 100644
--- a/tanh.c
+++ b/tanh.c
@@ -69,6 +69,7 @@ mpfr_tanh (y, xt, rnd_mode)
/* tanh(0) = 0 */
if(!MPFR_NOTZERO(xt))
{
+ MPFR_SET_ZERO(y);
MPFR_SET_SAME_SIGN(y,xt);
return 0;
}