summaryrefslogtreecommitdiff
path: root/ext/pcre/php_pcre.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/pcre/php_pcre.c')
-rw-r--r--ext/pcre/php_pcre.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c
index ee340829ee..4a796062ec 100644
--- a/ext/pcre/php_pcre.c
+++ b/ext/pcre/php_pcre.c
@@ -486,6 +486,7 @@ static PHP_RINIT_FUNCTION(pcre)
mdata_used = 0;
#endif
+ PCRE_G(error_code) = PHP_PCRE_NO_ERROR;
PCRE_G(gctx_zmm) = pcre2_general_context_create(php_pcre_emalloc, php_pcre_efree, NULL);
if (!PCRE_G(gctx_zmm)) {
return FAILURE;