]> Dogcows Code - chaz/tar/commitdiff
(FOLD): Do not assume that characters are unsigned.
authorPaul Eggert <eggert@cs.ucla.edu>
Tue, 31 Oct 2000 06:02:53 +0000 (06:02 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Tue, 31 Oct 2000 06:02:53 +0000 (06:02 +0000)
lib/fnmatch.c

index 90930e43d150e7446907c6e7a17ab737325743fa..ce55c7ff04b6a6936899e6348c9aecdda72a5b5f 100644 (file)
@@ -61,7 +61,9 @@ fnmatch (const char *pattern, const char *string, int flags)
   register char c;
 
 /* Note that this evaluates C many times.  */
-# define FOLD(c) ((flags & FNM_CASEFOLD) && ISUPPER (c) ? tolower (c) : (c))
+# define FOLD(c) ((flags & FNM_CASEFOLD) && ISUPPER ((unsigned char) (c)) \
+                  ? tolower ((unsigned char) (c)) \
+                  : (c))
 
   while ((c = *p++) != '\0')
     {
This page took 0.025922 seconds and 4 git commands to generate.