fix memory leak uncovered by the pcre_extra.phpt test

This commit is contained in:
Nuno Lopes 2006-06-14 17:52:56 +00:00
parent a7bc286638
commit a943d234f5

View File

@ -343,6 +343,9 @@ PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(char *regex, int regex_le
if (re == NULL) {
php_error_docref(NULL TSRMLS_CC,E_WARNING, "Compilation failed: %s at offset %d", error, erroffset);
efree(pattern);
if (tables) {
pefree((void*)tables, 1);
}
return NULL;
}