fixes for windows and 5.3 compatibility
[m6w6/ext-http] / php_http_property_proxy.c
index f4d352300cee50da02405c5ece530d0f3f568600..781c0c0ccc5c60e67ed8d579bc93d7406b46efbd 100644 (file)
@@ -91,7 +91,11 @@ zend_object_value php_http_property_proxy_object_new_ex(zend_class_entry *ce, ph
 
        o = ecalloc(1, sizeof(*o));
        zend_object_std_init((zend_object *) o, ce TSRMLS_CC);
+#if PHP_VERSION_ID < 50339
+       zend_hash_copy(((zend_object *) o)->properties, &(ce->default_properties), (copy_ctor_func_t) zval_add_ref, NULL, sizeof(zval*));
+#else
        object_properties_init((zend_object *) o, ce);
+#endif
 
        if (ptr) {
                *ptr = o;