diff options
author | Jakub Jelinek <jakub@redhat.com> | 2009-04-27 14:33:59 +0000 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2009-04-27 14:33:59 +0000 |
commit | 83489168c2447e3fe351dbb302b1026dc9fc512c (patch) | |
tree | 8c0029fbf2d97cd352310c6a793bb15745a24ec4 /sysdeps/ieee754/dbl-64/s_expm1.c | |
parent | 51211e710a024163f91ffd5ed29908faa3cd41e7 (diff) |
Updated to fedora-glibc-20090427T1419cvs/fedora-glibc-2_9_90-22
Diffstat (limited to 'sysdeps/ieee754/dbl-64/s_expm1.c')
-rw-r--r-- | sysdeps/ieee754/dbl-64/s_expm1.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sysdeps/ieee754/dbl-64/s_expm1.c b/sysdeps/ieee754/dbl-64/s_expm1.c index bfd15b2e31..324354336e 100644 --- a/sysdeps/ieee754/dbl-64/s_expm1.c +++ b/sysdeps/ieee754/dbl-64/s_expm1.c @@ -112,6 +112,7 @@ static char rcsid[] = "$NetBSD: s_expm1.c,v 1.8 1995/05/10 20:47:09 jtc Exp $"; * to produce the hexadecimal values shown. */ +#include <errno.h> #include "math.h" #include "math_private.h" #define one Q[0] @@ -159,7 +160,10 @@ Q[] = {1.0, -3.33333333333331316428e-02, /* BFA11111 111110F4 */ return x+x; /* NaN */ else return (xsb==0)? x:-1.0;/* exp(+-inf)={inf,-1} */ } - if(x > o_threshold) return huge*huge; /* overflow */ + if(x > o_threshold) { + __set_errno (ERANGE); + return huge*huge; /* overflow */ + } } if(xsb!=0) { /* x < -56*ln2, return -1.0 with inexact */ if(x+tiny<0.0) /* raise inexact */ |