# HG changeset patch # User Andrew Choi # Date 980696517 0 # Node ID e5dea4a61cabe016e58883761e47f8300e31bf9f # Parent 11b616e892bef0d884e9aee287941294ebd71972 * fontset.c (fontset_pattern_regexp): Allocate three more bytes to regex for '^', '$', and '\0'. diff -r 11b616e892be -r e5dea4a61cab src/ChangeLog --- a/src/ChangeLog Sun Jan 28 13:13:00 2001 +0000 +++ b/src/ChangeLog Sun Jan 28 15:41:57 2001 +0000 @@ -1,5 +1,8 @@ 2001-01-28 Andrew Choi + * fontset.c (fontset_pattern_regexp): Allocate three more bytes to + regex for '^', '$', and '\0'. + * alloc.c (allocate_string) [macintosh]: Call check_string_bytes only if current_sblock has been initialized. diff -r 11b616e892be -r e5dea4a61cab src/fontset.c --- a/src/fontset.c Sun Jan 28 13:13:00 2001 +0000 +++ b/src/fontset.c Sun Jan 28 15:41:57 2001 +0000 @@ -719,7 +719,7 @@ || strcmp (XSTRING (pattern)->data, CACHED_FONTSET_NAME)) { /* We must at first update the cached data. */ - char *regex = (char *) alloca (XSTRING (pattern)->size * 2); + char *regex = (char *) alloca (XSTRING (pattern)->size * 2 + 3); char *p0, *p1 = regex; /* Convert "*" to ".*", "?" to ".". */