--- gnupg-1.3.2/gnupg.c~ 1970-01-01 17:13:08.000000000 +0800 +++ gnupg-1.3.2/gnupg.c 2013-01-14 00:39:10.759572226 +0800 @@ -179,7 +179,11 @@ ALLOC_HASHTABLE (intern->zo.properties); zend_hash_init (intern->zo.properties, 0, NULL, ZVAL_PTR_DTOR, 0); +#if PHP_VERSION_ID < 50399 zend_hash_copy (intern->zo.properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *)); +#else + object_properties_init(&(intern->zo), class_type); +#endif retval.handle = zend_objects_store_put(intern,NULL,(zend_objects_free_object_storage_t) gnupg_obj_dtor,NULL TSRMLS_CC); retval.handlers = (zend_object_handlers *) & gnupg_object_handlers;