diff options
Diffstat (limited to 'sysdeps/libm-ieee754/s_log2f.c')
-rw-r--r-- | sysdeps/libm-ieee754/s_log2f.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/libm-ieee754/s_log2f.c b/sysdeps/libm-ieee754/s_log2f.c index 6415c37f53..da9dfb8324 100644 --- a/sysdeps/libm-ieee754/s_log2f.c +++ b/sysdeps/libm-ieee754/s_log2f.c @@ -53,8 +53,8 @@ static float zero = 0.0; k=0; if (ix < 0x00800000) { /* x < 2**-126 */ if ((ix&0x7fffffff)==0) - return -two25/zero; /* log(+-0)=-inf */ - if (ix<0) return (x-x)/zero; /* log(-#) = NaN */ + return -two25/(x-x); /* log(+-0)=-inf */ + if (ix<0) return (x-x)/(x-x); /* log(-#) = NaN */ k -= 25; x *= two25; /* subnormal number, scale up x */ GET_FLOAT_WORD(ix,x); } |