]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
Undefine min and/or max before defining to avoid redefinition warning
authorJim Meyering <jim@meyering.net>
Sat, 24 Jun 1995 21:10:12 +0000 (21:10 +0000)
committerJim Meyering <jim@meyering.net>
Sat, 24 Jun 1995 21:10:12 +0000 (21:10 +0000)
on systems.

src/cat.c
src/comm.c
src/join.c
src/sort.c
src/uniq.c

index de99b0dfd48b188d587376adb940c28594ade3f8..ca9d87ac89570805779069ff02a83e698d6c1c78 100644 (file)
--- a/src/cat.c
+++ b/src/cat.c
@@ -34,6 +34,8 @@
 #include "version.h"
 #include "error.h"
 
+/* Undefine, to avoid warning about redefinition on some systems.  */
+#undef max
 #define max(h,i) ((h) > (i) ? (h) : (i))
 
 char *stpcpy ();
index 1d27f75c594ab5a47602398dfa4219a109678f6a..e7d241d153a3b4bc5a61792d4fc0f391ce873212 100644 (file)
@@ -27,6 +27,8 @@
 #include "version.h"
 #include "error.h"
 
+/* Undefine, to avoid warning about redefinition on some systems.  */
+#undef min
 #define min(x, y) ((x) < (y) ? (x) : (y))
 
 /* The name this program was run with. */
index b17a2a75c09f3d19dee8e12ae37f1c2244d720dc..c0d098b5f9f1f8ae1860bcbf61e5351c95f3cae0 100644 (file)
@@ -36,6 +36,9 @@ char *xmalloc ();
 char *xrealloc ();
 static void usage ();
 
+/* Undefine, to avoid warning about redefinition on some systems.  */
+#undef min
+#undef max
 #define min(A, B) ((A) < (B) ? (A) : (B))
 #define max(A, B) ((A) > (B) ? (A) : (B))
 
index 0d03ec832c82147660c430b0a4041df1c27b6f4b..83f345ef877b3220ee9b1ee59a03707e00658fbb 100644 (file)
@@ -47,7 +47,10 @@ void free ();
 
 static void usage ();
 
+/* Undefine, to avoid warning about redefinition on some systems.  */
+#undef min
 #define min(a, b) ((a) < (b) ? (a) : (b))
+
 #define UCHAR_LIM (UCHAR_MAX + 1)
 #define UCHAR(c) ((unsigned char) (c))
 
index 5897c71660933c84a9c69d592d3dad17da362756..8f86e978fbf8dacb26f3c9a3ebb46555df348bbd 100644 (file)
@@ -30,6 +30,8 @@
 #include "version.h"
 #include "error.h"
 
+/* Undefine, to avoid warning about redefinition on some systems.  */
+#undef min
 #define min(x, y) ((x) < (y) ? (x) : (y))
 
 static char *find_field ();