summary refs log tree commit diff
path: root/stdlib/gmp-impl.h
diff options
context:
space:
mode:
authorGabriel F. T. Gomes <gftg@linux.vnet.ibm.com>2017-05-26 19:29:20 -0300
committerGabriel F. T. Gomes <gftg@linux.vnet.ibm.com>2017-06-01 20:44:22 -0300
commit09103e40252454e906a0b8543a142fc96b4c17c1 (patch)
tree81053ef42965eb802105c51c7cdf9ed860e0511c /stdlib/gmp-impl.h
parent6da85a0daf65a407f942622e23fc20b37b80168c (diff)
downloadglibc-09103e40252454e906a0b8543a142fc96b4c17c1.tar.gz
glibc-09103e40252454e906a0b8543a142fc96b4c17c1.tar.xz
glibc-09103e40252454e906a0b8543a142fc96b4c17c1.zip
Include sys/param.h in stdlib/gmp-impl.h instead of redefining MAX/MIN
In stdlib/gmp-impl.h, the macros MAX and MIN are defined exactly the same
as in sys/param.h.  This patch removes the redefinition and makes
gmp-impl.h include sys/param.h instead.

Tested for powerpc64le and s390x.

	* stdlib/gmp-impl.h: Include sys/param.h instead of redefining the
	macros MAX and MIN.
Diffstat (limited to 'stdlib/gmp-impl.h')
-rw-r--r--stdlib/gmp-impl.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/stdlib/gmp-impl.h b/stdlib/gmp-impl.h
index a6594ffe4b..89693c4f0b 100644
--- a/stdlib/gmp-impl.h
+++ b/stdlib/gmp-impl.h
@@ -64,12 +64,8 @@ along with the GNU MP Library; see the file COPYING.LIB.  If not, see
 #define inline			/* Empty */
 #endif
 
-#ifndef MIN
-#define MIN(l,o) ((l) < (o) ? (l) : (o))
-#endif
-#ifndef MAX
-#define MAX(h,i) ((h) > (i) ? (h) : (i))
-#endif
+/* Get MAX/MIN macros.  */
+#include <sys/param.h>
 
 /* Field access macros.  */
 #define SIZ(x) ((x)->_mp_size)