]> granicus.if.org Git - php/commitdiff
Mark all strings stored in SHM as IS_INTERNED to avoid refcounting
authorDmitry Stogov <dmitry@zend.com>
Tue, 6 May 2014 08:41:27 +0000 (12:41 +0400)
committerDmitry Stogov <dmitry@zend.com>
Tue, 6 May 2014 08:41:27 +0000 (12:41 +0400)
ext/opcache/zend_persist.c

index ca3c1882d957b11380bbeeda3aa88e50351f25b0..33a99ee9c0fb973f5e5732af88e4c201e835edc8 100644 (file)
@@ -43,6 +43,7 @@
                new_str = _zend_shared_memdup((void*)str, _STR_HEADER_SIZE + (str)->len + 1, 0 TSRMLS_CC); \
                        STR_RELEASE(str); \
                str = new_str; \
+               GC_FLAGS(str) = IS_STR_INTERNED | IS_STR_PERMANENT; \
                } \
     } while (0)
 # define zend_accel_memdup_string(str) \