summaryrefslogtreecommitdiff
path: root/ext/pcre/php_pcre.c
diff options
context:
space:
mode:
authorAndrei Zmievski <andrei@php.net>2001-05-15 18:00:35 +0000
committerAndrei Zmievski <andrei@php.net>2001-05-15 18:00:35 +0000
commit58f7df0ae4665209acd92609658b23cd91ede2f7 (patch)
tree4098aa4a1e9841cfcf2b128f8501399e76ef49a1 /ext/pcre/php_pcre.c
parent12a5c62402095530b431d58e2128f19d9a1924e8 (diff)
downloadphp-git-58f7df0ae4665209acd92609658b23cd91ede2f7.tar.gz
Revert previous commit - callback_name does need to be checked because
it is set conditional on is_callable_replace.
Diffstat (limited to 'ext/pcre/php_pcre.c')
-rw-r--r--ext/pcre/php_pcre.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c
index b6db493ee3..4344591cd6 100644
--- a/ext/pcre/php_pcre.c
+++ b/ext/pcre/php_pcre.c
@@ -989,7 +989,8 @@ static void preg_replace_impl(INTERNAL_FUNCTION_PARAMETERS, zend_bool is_callabl
zval_copy_ctor(return_value);
return;
}
- efree(callback_name);
+ if (callback_name)
+ efree(callback_name);
SEPARATE_ZVAL(regex);
SEPARATE_ZVAL(subject);