From 32a17bf442da79747f11eeab5ed7fa0f3b8a511f Mon Sep 17 00:00:00 2001 From: ehofman Date: Fri, 20 Feb 2004 07:54:26 +0000 Subject: [PATCH] Remove truncf() all together. --- src/Cockpit/panel.cxx | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/Cockpit/panel.cxx b/src/Cockpit/panel.cxx index 16d7b7792..871ca97f3 100644 --- a/src/Cockpit/panel.cxx +++ b/src/Cockpit/panel.cxx @@ -53,13 +53,6 @@ // my hardware/driver requires many more. #define POFF_UNITS 4 -#ifndef HAVE_TRUNCF -inline float truncf (float d) { - return (d < 0) ? -floorf(-d) : floorf(d); -} -#endif - - //////////////////////////////////////////////////////////////////////// // Local functions. //////////////////////////////////////////////////////////////////////// @@ -1125,7 +1118,7 @@ FGTextLayer::Chunk::getValue () const break; case DOUBLE_VALUE: double d = _offs + _node->getFloatValue() * _mult; - if (_trunc) d = truncf(d); + if (_trunc) d = (d < 0) ? -floorf(-d) : floorf(d); sprintf(_buf, _fmt.c_str(), d); break; } -- 2.39.5