|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #39229 curl_exec hang on fiew cases of proxy connections
Submitted: 2006-10-22 19:03 UTC Modified: 2006-10-22 22:16 UTC
From: ludiqely at gmail dot com Assigned:
Status: Not a bug Package: cURL related
PHP Version: 5.1.6 OS: linux
Private report: No CVE-ID: None
 [2006-10-22 19:03 UTC] ludiqely at gmail dot com
I've used exactly socks connections.
This code create this problem:

php hang on this line with curl_exec function

Reproduce code:
$hCurl = curl_init();
curl_setopt ($hCurl, CURLOPT_URL, "");
curl_setopt ($hCurl, CURLOPT_HEADER, 0);
curl_setopt ($hCurl, CURLOPT_PROXY, "");
curl_setopt ($hCurl, CURLOPT_TIMEOUT, 7);
curl_setopt ($hCurl, CURLOPT_CONNECTTIMEOUT, 7);
curl_setopt ($hCurl, CURLE_OPERATION_TIMEOUTED, 7);
curl_setopt ($hCurl, CURLOPT_DNS_CACHE_TIMEOUT, 7);
curl_setopt ($hCurl, CURLOPT_RETURNTRANSFER, 1);
print 'before curl_exec';
$out = curl_exec ($hCurl);
print $out;

Expected result:
Expected exit from the function under the specified timeout.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2006-10-22 22:16 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

Any hangs in curl_exec() are a direct result of "hangs" inside 
the libcurl code and as such are not a PHP bug.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Tue Mar 02 21:01:24 2021 UTC