From d581a24a365c5a8650ab5774f81de9e85eab640d Mon Sep 17 00:00:00 2001 From: Jeff Johnston Date: Tue, 4 Feb 2014 20:49:53 +0000 Subject: [PATCH] 2014-02-04 Matthias Braun * libm/mathfp/sf_numtest.c: Fix NaN/Inf detection logic. --- newlib/ChangeLog | 4 ++++ newlib/libm/mathfp/sf_numtest.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/newlib/ChangeLog b/newlib/ChangeLog index 4318bff8a..835d63d24 100644 --- a/newlib/ChangeLog +++ b/newlib/ChangeLog @@ -1,3 +1,7 @@ +2014-02-04 Matthias Braun + + * libm/mathfp/sf_numtest.c: Fix NaN/Inf detection logic. + 2014-01-20 Corinna Vinschen * libc/include/setjmp.h (longjmp): Fix copy/paste error. diff --git a/newlib/libm/mathfp/sf_numtest.c b/newlib/libm/mathfp/sf_numtest.c index 675086c41..00bab3a9d 100644 --- a/newlib/libm/mathfp/sf_numtest.c +++ b/newlib/libm/mathfp/sf_numtest.c @@ -40,7 +40,7 @@ _DEFUN (numtestf, (float), } /* Check for not a number or infinity. */ - if (exp == 0x7f8) + if (exp == 0xff) { if(wx & 0x7fffff) return (NAN);