* fix bug#14826 (Race condition in http_request_dtor)
authorMichael Wallner <mike@php.net>
Mon, 20 Oct 2008 13:46:37 +0000 (13:46 +0000)
committerMichael Wallner <mike@php.net>
Mon, 20 Oct 2008 13:46:37 +0000 (13:46 +0000)
http_request_api.c

index ab6920098d2b0310dcb0862ff9af2a2247794e69..ad7f88e7c1ec60a5677a1c50c5c8067e0f067fe4 100644 (file)
@@ -316,8 +316,8 @@ PHP_HTTP_API void _http_request_dtor(http_request *request)
 {
        TSRMLS_FETCH_FROM_CTX(request->tsrm_ls);
        
-       http_curl_free(&request->ch);
        http_request_reset(request);
+       http_curl_free(&request->ch);
        
        phpstr_dtor(&request->_cache.cookies);
        zend_hash_destroy(&request->_cache.options);