Explorar o código

fix warning when sizeof uchar_t is 8 bits

Mike Frysinger %!s(int64=18) %!d(string=hai) anos
pai
achega
aaf2fdcab5
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      libc/misc/regex/regex_old.c

+ 4 - 0
libc/misc/regex/regex_old.c

@@ -3316,11 +3316,15 @@ PREFIX(regex_compile) (ARG_PREFIX(pattern), ARG_PREFIX(size), syntax, bufp)
                         PATFETCH (c);
                         if ((c == ':' && *p == ']') || p == pend)
                           break;
+#if CHAR_CLASS_MAX_LENGTH != 256
 			if (c1 < CHAR_CLASS_MAX_LENGTH)
 			  str[c1++] = c;
 			else
 			  /* This is in any case an invalid class name.  */
 			  str[0] = '\0';
+#else
+			  str[c1++] = c;
+#endif
                       }
                     str[c1] = '\0';