diff options
author | Christoph M. Becker <cmbecker69@gmx.de> | 2018-09-05 15:11:09 +0200 |
---|---|---|
committer | Christoph M. Becker <cmbecker69@gmx.de> | 2018-09-05 15:11:09 +0200 |
commit | f94518dca14010693668c72487af47a68c002a8b (patch) | |
tree | a826603274082ac955a527f41a0590b818cac188 /ext/reflection/php_reflection.c | |
parent | 8939c4d96b8382abe84f35e69f4f6ebd6f0f749d (diff) | |
parent | 21cd552e1e6685048ed159091274a8311b84d4c8 (diff) | |
download | php-git-f94518dca14010693668c72487af47a68c002a8b.tar.gz |
Merge branch 'PHP-7.3'
* PHP-7.3:
Fix #74454: Wrong exception being thrown when using ReflectionMethod
Diffstat (limited to 'ext/reflection/php_reflection.c')
-rw-r--r-- | ext/reflection/php_reflection.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 8fe8da071a..eeb3ac66b8 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -2974,8 +2974,10 @@ ZEND_METHOD(reflection_method, __construct) switch (Z_TYPE_P(classname)) { case IS_STRING: if ((ce = zend_lookup_class(Z_STR_P(classname))) == NULL) { - zend_throw_exception_ex(reflection_exception_ptr, 0, - "Class %s does not exist", Z_STRVAL_P(classname)); + if (!EG(exception)) { + zend_throw_exception_ex(reflection_exception_ptr, 0, + "Class %s does not exist", Z_STRVAL_P(classname)); + } if (classname == &ztmp) { zval_ptr_dtor_str(&ztmp); } |