From: Tobias Oetiker Date: Mon, 24 Aug 2009 12:02:32 +0000 (+0000) Subject: call fpclass only once when replacing isnan for solaris X-Git-Tag: 1.4.0~45 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4675f352b01f877ada521989bb9a1f993c5b7c17;p=thirdparty%2Frrdtool-1.x.git call fpclass only once when replacing isnan for solaris git-svn-id: svn://svn.oetiker.ch/rrdtool/trunk/program@1904 a5681a0c-68f1-0310-ab6d-d61299d08faa --- diff --git a/src/rrd_config_bottom.h b/src/rrd_config_bottom.h index d04e592a..a569197a 100644 --- a/src/rrd_config_bottom.h +++ b/src/rrd_config_bottom.h @@ -175,7 +175,8 @@ char *strchr (), *strrchr (); # ifdef isinf # undef isinf # endif -# define isinf(a) (fpclass(a) == FP_NINF || fpclass(a) == FP_PINF) +# define isinf(a) (!!(fpclass(a) & (FP_SNAN|FP_QNAN))) + #endif /* solaris 10 it defines isnan such that only forte can compile it ... bad bad */