regex: avoid compiler warning
authorEric Blake <eblake@redhat.com>
Mon, 11 Jul 2011 13:32:39 +0000 (07:32 -0600)
committerEric Blake <eblake@redhat.com>
Mon, 11 Jul 2011 13:33:39 +0000 (07:33 -0600)
Although glibc leaks strcasecmp through <string.h>, this behavior
is not required by POSIX, and HP NonStop needs <strings.h>

* lib/regex.c (includes): Include <strings.h>, for use of
strcasecmp in regcomp.c.
Reported by Jachim Schmitz.

Signed-off-by: Eric Blake <eblake@redhat.com>
ChangeLog
lib/regex.c

index 41e97e2408823bdd5b1bd0859c6e9e4358a87145..9f98405ab3db2ffcd3e3b8a0d0804479557c9264 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-07-11  Eric Blake  <eblake@redhat.com>
+
+       regex: avoid compiler warning
+       * lib/regex.c (includes): Include <strings.h>, for use of
+       strcasecmp in regcomp.c.
+       Reported by Jachim Schmitz.
+
 2011-07-09  Paul Eggert  <eggert@cs.ucla.edu>
 
        stdint: respect system's intmax_t if INTMAX_MAX
index 210bf91c4818cff63462d4a7ca076afae981dd0d..af47056d73d2a54cf77657182de704a8d438ce97 100644 (file)
@@ -53,6 +53,7 @@
    GNU regex allows.  Include it before <regex.h>, which correctly
    #undefs RE_DUP_MAX and sets it to the right value.  */
 #include <limits.h>
+#include <strings.h>
 
 #include <regex.h>
 #include "regex_internal.h"