Fix ITS#1963 buffer size check in string_expand()

This commit is contained in:
Howard Chu 2002-08-26 13:39:26 +00:00
parent fe336b15c5
commit f3ae2b87e3

View File

@ -1541,7 +1541,7 @@ string_expand(
*dp = '\0';
i = matches[n].rm_so;
l = matches[n].rm_eo;
for ( ; size < 512 && i < l; size++, i++ ) {
for ( ; size < bufsiz && i < l; size++, i++ ) {
*dp++ = match[i];
size++;
}