]> granicus.if.org Git - php/commitdiff
Add missing initialization check to RegexIterator::getRegex()
authorNikita Popov <nikita.ppv@gmail.com>
Fri, 14 Aug 2020 08:27:09 +0000 (10:27 +0200)
committerNikita Popov <nikita.ppv@gmail.com>
Fri, 14 Aug 2020 08:41:36 +0000 (10:41 +0200)
ext/spl/spl_iterators.c

index cce9477ed50d87a721346215116aff14d6bb2bd5..7dd4b29c05b21c3f4d93b97daf76e18632f94fb6 100644 (file)
@@ -2099,6 +2099,8 @@ SPL_METHOD(RegexIterator, getRegex)
                return;
        }
 
+       SPL_FETCH_AND_CHECK_DUAL_IT(intern, ZEND_THIS);
+
        RETURN_STR_COPY(intern->u.regex.regex);
 } /* }}} */