Remove local redefinition of MAX macro.
authorRoland McGrath <roland@hack.frob.com>
Wed, 15 Aug 2012 18:40:41 +0000 (11:40 -0700)
committerRoland McGrath <roland@hack.frob.com>
Wed, 15 Aug 2012 18:40:41 +0000 (11:40 -0700)
ChangeLog
string/str-two-way.h

index 886c420..d1d4e9e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2012-08-15  Roland McGrath  <roland@hack.frob.com>
 
+       * string/str-two-way.h: Include <sys/param.h>.
+       (MAX): Macro removed.
+
        * sysdeps/x86_64/multiarch/strstr-c.c: Add copyright header.
        Move #define and #undef of memmove to just before and after
        including <string.h>.
index 1b2a8bd..22e7539 100644 (file)
@@ -1,5 +1,5 @@
 /* Byte-wise substring search, using the Two-Way algorithm.
-   Copyright (C) 2008, 2010 Free Software Foundation, Inc.
+   Copyright (C) 2008-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Written by Eric Blake <ebb9@byu.net>, 2008.
 
@@ -43,6 +43,7 @@
 
 #include <limits.h>
 #include <stdint.h>
+#include <sys/param.h>                  /* Defines MAX.  */
 
 /* We use the Two-Way string matching algorithm, which guarantees
    linear complexity with constant space.  Additionally, for long
 # define LONG_NEEDLE_THRESHOLD SIZE_MAX
 #endif
 
-#ifndef MAX
-# define MAX(a, b) ((a < b) ? (b) : (a))
-#endif
-
 #ifndef CANON_ELEMENT
 # define CANON_ELEMENT(c) c
 #endif