ceil, trunc, round: Fix gcc warnings.
authorBruno Haible <bruno@clisp.org>
Sat, 25 Dec 2010 01:58:27 +0000 (02:58 +0100)
committerBruno Haible <bruno@clisp.org>
Sat, 25 Dec 2010 01:58:27 +0000 (02:58 +0100)
* lib/ceil.c (MIN): Undefine before redefining.
* lib/trunc.c (MIN): Likewise.
* lib/round.c (MIN): Likewise.
Include <math.h> first.

ChangeLog
lib/ceil.c
lib/round.c
lib/trunc.c

index 6124d25..be6b431 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
 2010-12-24  Bruno Haible  <bruno@clisp.org>
 
+       ceil, trunc, round: Fix gcc warnings.
+       * lib/ceil.c (MIN): Undefine before redefining.
+       * lib/trunc.c (MIN): Likewise.
+       * lib/round.c (MIN): Likewise.
+       Include <math.h> first.
+
+2010-12-24  Bruno Haible  <bruno@clisp.org>
+
        select tests: Avoid failures on OSF/1 5.1.
        * tests/test-select.c (test_accept_first, test_socket_pair): Ignore
        failure of closing the last socket; it may fail with ECONNRESET.
index 2ed1654..5882cad 100644 (file)
@@ -23,6 +23,8 @@
 
 #include <float.h>
 
+#undef MIN
+
 #ifdef USE_LONG_DOUBLE
 # define FUNC ceill
 # define DOUBLE long double
index 07ec4cd..df56266 100644 (file)
 
 #include <config.h>
 
-#include <float.h>
+/* Specification.  */
 #include <math.h>
 
+#include <float.h>
+
+#undef MIN
+
 #ifdef USE_LONG_DOUBLE
 # define ROUND roundl
 # define FLOOR floorl
index 350459b..347d9ac 100644 (file)
@@ -23,6 +23,8 @@
 
 #include <float.h>
 
+#undef MIN
+
 #ifdef USE_LONG_DOUBLE
 # define FUNC truncl
 # define DOUBLE long double