RC manipulation cleanup

This commit is contained in:
Xinchen Hui 2017-11-01 10:25:10 +08:00
parent 0056f52f50
commit a8a17a72b0
16 changed files with 168 additions and 408 deletions

View file

@ -2602,9 +2602,7 @@ PHPAPI void php_pcre_grep_impl(pcre_cache_entry *pce, zval *input, zval *return
/* If the entry fits our requirements */
if ((count > 0 && !invert) || (count == PCRE_ERROR_NOMATCH && invert)) {
if (Z_REFCOUNTED_P(entry)) {
Z_ADDREF_P(entry);
}
Z_TRY_ADDREF_P(entry);
/* Add to return array */
if (string_key) {