summaryrefslogtreecommitdiff
path: root/ext/opcache
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2019-12-10 15:22:31 +0100
committerNikita Popov <nikita.ppv@gmail.com>2019-12-10 15:22:31 +0100
commit5ddcacac2ebc30d573eb1cb4a121a1c02d61c6aa (patch)
tree597f561c05b2759e27fc7b55525d24333d1c13e7 /ext/opcache
parentd6f86caa11f3dcc3ec4c950ae34e01aa8fe726b0 (diff)
downloadphp-git-5ddcacac2ebc30d573eb1cb4a121a1c02d61c6aa.tar.gz
Fix incorrect zend_try usage
Diffstat (limited to 'ext/opcache')
-rw-r--r--ext/opcache/ZendAccelerator.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/ext/opcache/ZendAccelerator.c b/ext/opcache/ZendAccelerator.c
index 3f65123aed..0b66ab6e6e 100644
--- a/ext/opcache/ZendAccelerator.c
+++ b/ext/opcache/ZendAccelerator.c
@@ -3873,10 +3873,13 @@ static void preload_check_windows_restrictions(zend_class_entry *scope) {
static inline int preload_update_class_constants(zend_class_entry *ce) {
/* This is a separate function to work around what appears to be a bug in GCC
* maybe-uninitialized analysis. */
+ int result;
zend_try {
- return zend_update_class_constants(ce);
+ result = zend_update_class_constants(ce);
+ } zend_catch {
+ result = FAILURE;
} zend_end_try();
- return FAILURE;
+ return result;
}
static zend_class_entry *preload_load_prop_type(zend_property_info *prop, zend_string *name) {