Skip to content

Commit

Permalink
Use RETURN_THROWS() in a few places
Browse files Browse the repository at this point in the history
  • Loading branch information
kocsismate committed Jan 1, 2021
1 parent 82f9e00 commit b23c865
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ext/reflection/php_reflection.c
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ static void _class_string(smart_str *str, zend_class_entry *ce, zval *obj, char
_class_const_string(str, ZSTR_VAL(key), c, ZSTR_VAL(sub_indent));
if (UNEXPECTED(EG(exception))) {
zend_string_release(sub_indent);
return;
RETURN_THROWS();
}
} ZEND_HASH_FOREACH_END();
}
Expand Down Expand Up @@ -1802,7 +1802,7 @@ ZEND_METHOD(ReflectionFunctionAbstract, getStaticVariables)
}
ZEND_HASH_FOREACH_VAL(ht, val) {
if (UNEXPECTED(zval_update_constant_ex(val, fptr->common.scope) != SUCCESS)) {
return;
RETURN_THROWS();
}
} ZEND_HASH_FOREACH_END();
zend_hash_copy(Z_ARRVAL_P(return_value), ht, zval_add_ref);
Expand Down Expand Up @@ -4503,7 +4503,7 @@ ZEND_METHOD(ReflectionClass, getConstant)
GET_REFLECTION_OBJECT_PTR(ce);
ZEND_HASH_FOREACH_PTR(&ce->constants_table, c) {
if (UNEXPECTED(zval_update_constant_ex(&c->value, ce) != SUCCESS)) {
return;
RETURN_THROWS();
}
} ZEND_HASH_FOREACH_END();
if ((c = zend_hash_find_ptr(&ce->constants_table, name)) == NULL) {
Expand Down

0 comments on commit b23c865

Please sign in to comment.