]> granicus.if.org Git - php/commitdiff
Mark PCRE locale key as local persistent
authorNikita Popov <nikita.ppv@gmail.com>
Tue, 13 Aug 2019 12:35:08 +0000 (14:35 +0200)
committerNikita Popov <nikita.ppv@gmail.com>
Tue, 13 Aug 2019 12:49:59 +0000 (14:49 +0200)
ext/pcre/php_pcre.c

index cae276134c38a86255dc09f8e393531c31bded2a..a3d2837c381b99df4fb4135a18d0961311e0f139 100644 (file)
@@ -761,6 +761,7 @@ PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(zend_string *regex)
                                return NULL;
                        }
                        _k = zend_string_init(ZSTR_VAL(BG(locale_string)), ZSTR_LEN(BG(locale_string)), 1);
+                       GC_MAKE_PERSISTENT_LOCAL(_k);
                        zend_hash_add_ptr(&char_tables, _k, (void *)tables);
                        zend_string_release(_k);
                }