#33559 [Opn->Bgs]: curl_close gives a seg fault when used on a multi cURL resource
| From: | dev at null dot com | Date: | Mon, 04 Jul 2005 00:52:48 +0000 |
| Subject: | #33559 [Opn->Bgs]: curl_close gives a seg fault when used on a multi cURL resource | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-81342@lists.php.net to get a copy of this message | ||
ID: 33559
User updated by: dev at null dot com
Reported By: dev at null dot com
-Status: Open
+Status: Bogus
Bug Type: Unknown/Other Function
Operating System: Redhat 9
PHP Version: 5.0.4
New Comment:
Actually - I have some more information on this bug. I will reopen a
new ticket with some sample code to reliably generate it.
Previous Comments:
------------------------------------------------------------------------
[2005-07-04 02:36:56] dev at null dot com
Description:
------------
A common oversight if migrating from a normal cURL interface to
multi-curl is leaving in a curl_close() command. This causes a PHP seg
fault if performed after curl_multi_remove_handle. The problem was not
reproducible all the time - one key to it being reproduced was having
a. Multiple cURL handles
b. Closing the first $mh using curl_multi_close; then followed by a new
curl_multi_init.
This may be fixed in the CVS (re #33222 - a similar but not identical
problem with the function) - I am not sure.
Reproduce code:
---------------
$mh = curl_multi_init();
... curl_multi_exec etc.
curl_multi_remove_handle($mh,$ch);
// seg fault here:
curl_close($ch);
Expected result:
----------------
Should give a graceful error, not a seg fault.
Actual result:
--------------
seg fault
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=33559&edit=1