summaryrefslogtreecommitdiff
path: root/ext/pcre/php_pcre.c
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2003-01-19 00:45:53 +0000
committerIlia Alshanetsky <iliaa@php.net>2003-01-19 00:45:53 +0000
commit3d8e54f3a2f72eeaf22a5ffd66a7e5465f60127c (patch)
tree1784e782a671b83758c0c836088026f73897c0ef /ext/pcre/php_pcre.c
parentadd3ec4e0ba076db7cdece4bfdb852b8333e198d (diff)
downloadphp-git-3d8e54f3a2f72eeaf22a5ffd66a7e5465f60127c.tar.gz
Changed php_error to php_error_docref.
Diffstat (limited to 'ext/pcre/php_pcre.c')
-rw-r--r--ext/pcre/php_pcre.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c
index 5bd8204410..d777c47dd6 100644
--- a/ext/pcre/php_pcre.c
+++ b/ext/pcre/php_pcre.c
@@ -633,7 +633,7 @@ static int preg_do_repl_func(zval *function, char *subject, int *offsets, int co
result_len = Z_STRLEN_P(retval_ptr);
zval_ptr_dtor(&retval_ptr);
} else {
- php_error(E_WARNING, "Unable to call custom replacement function");
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to call custom replacement function");
result_len = offsets[1] - offsets[0];
*result = estrndup(&subject[offsets[0]], result_len);
}
@@ -776,7 +776,7 @@ PHPAPI char *php_pcre_replace(char *regex, int regex_len,
eval = preg_options & PREG_REPLACE_EVAL;
if (is_callable_replace) {
if (eval) {
- php_error(E_WARNING, "/e modifier cannot be used with replacement callback");
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "/e modifier cannot be used with replacement callback");
return NULL;
}
} else {
@@ -1054,8 +1054,7 @@ static void preg_replace_impl(INTERNAL_FUNCTION_PARAMETERS, zend_bool is_callabl
convert_to_string_ex(replace);
if (is_callable_replace) {
if (!zend_is_callable(*replace, 0, &callback_name)) {
- php_error(E_WARNING, "%s() requires argument 2, '%s', to be a valid callback",
- get_active_function_name(TSRMLS_C), callback_name);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "requires argument 2, '%s', to be a valid callback", callback_name);
efree(callback_name);
*return_value = **subject;
zval_copy_ctor(return_value);