summaryrefslogtreecommitdiff
path: root/libc/misc/regex
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-01-20 23:07:42 +0000
committerMike Frysinger <vapier@gentoo.org>2006-01-20 23:07:42 +0000
commitaaf2fdcab57b1b85a2cef6dafdda11a10d66defa (patch)
tree2b2cd382436fc093ec066ee4e07a8b0ee87f0b36 /libc/misc/regex
parent70d37cb4afa78201a9ec23df6792c64f4078c5a8 (diff)
fix warning when sizeof uchar_t is 8 bits
Diffstat (limited to 'libc/misc/regex')
-rw-r--r--libc/misc/regex/regex_old.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libc/misc/regex/regex_old.c b/libc/misc/regex/regex_old.c
index 85a1b8e6f..bb8aa762a 100644
--- a/libc/misc/regex/regex_old.c
+++ b/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';