@@ -271,7 +271,7 @@ PHP_GTK_API void phpg_init_object(void *object, zend_class_entry *ce TSRMLS_DC)
271271
272272 poh -> pi_hash = NULL ;
273273
274- #if PHP_VERSION_ID < 50399
274+ #if PHP_VERSION_ID < 50399
275275 zend_hash_copy (poh -> zobj .properties , & (ce -> default_properties ),
276276 (copy_ctor_func_t )zval_add_ref , (void * )(& tmp ),
277277 sizeof (zval * ));
@@ -288,7 +288,7 @@ PHP_GTK_API void phpg_init_object(void *object, zend_class_entry *ce TSRMLS_DC)
288288 prop_ce = prop_ce -> parent ;
289289 }
290290
291- zend_hash_find (& phpg_prop_info , prop_ce -> name , prop_ce -> name_length + 1 , (void * * ) & poh -> pi_hash );
291+ // zend_hash_find(&phpg_prop_info, prop_ce->name, prop_ce->name_length+1, (void **) &poh->pi_hash);
292292}
293293/* }}} */
294294
@@ -311,11 +311,7 @@ PHP_GTK_API zend_class_entry* phpg_register_class(const char *class_name,
311311 phpg_class_key = g_quark_from_static_string (phpg_class_id );
312312 }
313313
314- memset (& ce , 0 , sizeof (ce ));
315-
316- ce .name = strdup (class_name );
317- ce .name_length = strlen (class_name );
318- ce .builtin_functions = class_methods ;
314+ INIT_CLASS_ENTRY_EX (ce , strdup (class_name ), strlen (class_name ), class_methods );
319315
320316 real_ce = zend_register_internal_class_ex (& ce , parent , NULL TSRMLS_CC );
321317
@@ -365,10 +361,7 @@ PHP_GTK_API zend_class_entry* phpg_register_interface(const char *iface_name,
365361 phpg_class_key = g_quark_from_static_string (phpg_class_id );
366362 }
367363
368- memset (& ce , 0 , sizeof (ce ));
369- ce .name = strdup (iface_name );
370- ce .name_length = strlen (iface_name );
371- ce .builtin_functions = iface_methods ;
364+ INIT_CLASS_ENTRY_EX (ce , strdup (iface_name ), strlen (iface_name ), iface_methods );
372365
373366 real_ce = zend_register_internal_interface (& ce TSRMLS_CC );
374367
0 commit comments