1998-11-19  Ulrich Drepper  <drepper@cygnus.com>

	* posix/regex.c (regex_compile): Handle extra long class names
	correctly.
This commit is contained in:
Ulrich Drepper 1998-11-19 18:39:58 +00:00
parent 50463d27cd
commit bece5ca7c1
2 changed files with 11 additions and 3 deletions

View File

@ -1,3 +1,8 @@
1998-11-19 Ulrich Drepper <drepper@cygnus.com>
* posix/regex.c (regex_compile): Handle extra long class names
correctly.
1998-11-19 Geoff Keating <geoffk@ozemail.com.au>
* elf/rtld.c (_dl_start): Handle weak undefined symbols in ld.so

View File

@ -2210,10 +2210,13 @@ regex_compile (pattern, size, syntax, bufp)
for (;;)
{
PATFETCH (c);
if ((c == ':' && *p == ']') || p == pend
|| c1 == CHAR_CLASS_MAX_LENGTH)
if ((c == ':' && *p == ']') || p == pend)
break;
str[c1++] = c;
if (c1 < CHAR_CLASS_MAX_LENGTH)
str[c1++] = c;
else
/* This is in any case an invalid class name. */
str[0] = '\0';
}
str[c1] = '\0';