fix mind effup
authorMichael Wallner <mike@php.net>
Thu, 24 Sep 2020 09:15:14 +0000 (11:15 +0200)
committerMichael Wallner <mike@php.net>
Thu, 24 Sep 2020 09:15:14 +0000 (11:15 +0200)
src/php_pq_object.c

index 6d80a1f5547f68364ac86ff424e40eef0d0c2f03..c8d1e50bc73d4b1df3c119c48dabf396b4223e2e 100644 (file)
@@ -103,11 +103,13 @@ static int apply_pi_to_ht(zval *p, void *a)
                zval zobj;
 
                ZVAL_OBJ(&zobj, &arg->pq_obj->zo);
+# if PHP_VERSION_ID < 70100
+               property = zend_read_property(arg->pq_obj->zo.ce, &zobj, pi->name->val, pi->name->len, 0, &tmp_prop);
+# else
                property = zend_read_property_ex(arg->pq_obj->zo.ce, &zobj, pi->name, 0, &tmp_prop);
-#elif PHP_VERSION_ID >= 70100
-               property = zend_read_property_ex(arg->pq_obj->zo.ce, &arg->pq_obj->zo, pi->name, 0, &tmp_prop);
+# endif
 #else
-               property = zend_read_property(arg->pq_obj->zo.ce, &arg->pq_obj->zo, pi->name->val, pi->name->len, 0, &tmp_prop);
+               property = zend_read_property_ex(arg->pq_obj->zo.ce, &arg->pq_obj->zo, pi->name, 0, &tmp_prop);
 #endif
                zend_hash_update(arg->ht, pi->name, property);
        }