From: Michael Wallner Date: Fri, 28 Oct 2005 11:49:13 +0000 (+0000) Subject: - all those handlers->add_ref(zobject) would prevent the objects from X-Git-Tag: RELEASE_0_17_0~13 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=d7b22bfb4a76664b4dcffa8644e19aba2e5338ab;p=m6w6%2Fext-http - all those handlers->add_ref(zobject) would prevent the objects from being freed when there's no more reference to them --- diff --git a/http_request_pool_api.c b/http_request_pool_api.c index 0faf275..188bb9d 100644 --- a/http_request_pool_api.c +++ b/http_request_pool_api.c @@ -103,7 +103,6 @@ PHP_HTTP_API STATUS _http_request_pool_attach(http_request_pool *pool, zval *req zend_llist_add_element(&pool->bodies, &body); ZVAL_ADDREF(request); - Z_OBJ_ADDREF_P(request); #if HTTP_DEBUG_REQPOOLS fprintf(stderr, "> %d HttpRequests attached to pool %p\n", zend_llist_count(&pool->handles), pool); @@ -310,7 +309,6 @@ void _http_request_pool_responsehandler(zval **req, CURL *ch TSRMLS_DC) #endif ZVAL_ADDREF(*req); - Z_OBJ_ADDREF_PP(req); zend_llist_add_element(&obj->pool->finished, req); http_request_object_responsehandler(obj, *req); } diff --git a/http_requestpool_object.c b/http_requestpool_object.c index 2281f40..9c008a6 100644 --- a/http_requestpool_object.c +++ b/http_requestpool_object.c @@ -148,7 +148,6 @@ void _http_requestpool_object_free(zend_object *object TSRMLS_DC) static void _http_requestpool_object_llist2array(zval **req, zval *array TSRMLS_DC) { ZVAL_ADDREF(*req); - Z_OBJ_ADDREF_PP(req); add_next_index_zval(array, *req); }