com php-src: Don't call Reflection::export() in --rf etc implementation: sapi/cli/php_cli.c
| From: | Nikita Popov | Date: | Fri, 30 Aug 2019 09:02:28 +0000 |
| Subject: | com php-src: Don't call Reflection::export() in --rf etc implementation: sapi/cli/php_cli.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-108155@lists.php.net to get a copy of this message | ||
Commit: 226fd52c76e9ef325ce660321a29b1f99c388ddf
Author: Nikita Popov <nikita.ppv@gmail.com> Fri, 30 Aug 2019 10:59:58 +0200
Parents: e1afd9b2137ea77c15516883c0f071cfdae763be
Branches: PHP-7.4 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=226fd52c76e9ef325ce660321a29b1f99c388ddf
Log:
Don't call Reflection::export() in --rf etc implementation
This method is deprecated ... instead simply directly print the
object.
Changed paths:
M sapi/cli/php_cli.c
Diff:
diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
index 0700e79..a305c36 100644
--- a/sapi/cli/php_cli.c
+++ b/sapi/cli/php_cli.c
@@ -1084,7 +1084,8 @@ static int do_cli(int argc, char **argv) /* {{{ */
zval_ptr_dtor(&tmp);
EG(exception) = NULL;
} else {
- zend_call_method_with_1_params(NULL, reflection_ptr, NULL, "export", NULL,
&ref);
+ zend_print_zval(&ref, 0);
+ zend_write("\n", 1);
}
zval_ptr_dtor(&ref);
zval_ptr_dtor(&arg);