|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2013-12-10 01:06 UTC] tobias382 at gmail dot com
Description:
------------
Using pecl_http 2.0.1 with raphf, propro, and spl enabled.
Test script:
---------------
<?php
$request = new \http\Client\Request('GET', 'http://google.com');
$client = new \http\Client('curl');
$client-<enqueue($request);
$client-<send();
Expected result:
----------------
No output.
Actual result:
--------------
PHP Fatal error: Uncaught exception 'http\Exception\UnexpectedValueException' with message 'Failed to locate "curl" client request handler' in temp.php:3
Stack trace:
#0 temp.php(3): http\Client->__construct('curl')
#1 {main}
thrown in temp.php on line 3
If no argument is passed to the http\Client constructor, the error reads "(null)" instead of "curl"
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 14:00:01 2025 UTC |
Apparently curl.h couldn't be found, though the installer didn't appear to generate any output to indicate this issue. I installed the libcurl4-openssl-dev package, uninstalled and reinstalled pecl_http, re-ran the test script, got a segfault, and obtained this backtrace: #0 0x00007fffefbf76c0 in ?? () #1 0x00007fffefe42f42 in php_persistent_handle_apply_cleanup_ex (pp=<optimized out>, arg=<optimized out>) at /home/matt/pear/temp/raphf/php_raphf.c:169 #2 0x00000000006f97e8 in zend_hash_apply_with_argument (ht=ht@entry=0x119e7d0, apply_func=apply_func@entry=0x7fffefe42f30 <php_persistent_handle_apply_cleanup_ex>, argument=0x1103820) at /build/buildd/php5-5.5.3+dfsg/Zend/zend_hash.c:740 #3 0x00007fffefe4200f in php_persistent_handle_list_dtor (provider=<optimized out>, list=<optimized out>) at /home/matt/pear/temp/raphf/php_raphf.c:199 #4 php_persistent_handle_list_free (provider=<optimized out>, list=0x119e958) at /home/matt/pear/temp/raphf/php_raphf.c:208 #5 php_persistent_handle_list_apply_dtor (listp=0x119e958, provider=<optimized out>) at /home/matt/pear/temp/raphf/php_raphf.c:219 #6 0x00000000006f97e8 in zend_hash_apply_with_argument (ht=ht@entry=0x11037d0, apply_func=apply_func@entry=0x7fffefe41ff0 <php_persistent_handle_list_apply_dtor>, argument=argument@entry=0x11037d0) at /build/buildd/php5-5.5.3+dfsg/Zend/zend_hash.c:740 #7 0x00007fffefe42723 in php_persistent_handle_hash_dtor (p=0x11037d0) at /home/matt/pear/temp/raphf/php_raphf.c:283 #8 0x00000000006f94f8 in zend_hash_destroy (ht=0x7ffff00452c8 <raphf_globals+8>) at /build/buildd/php5-5.5.3+dfsg/Zend/zend_hash.c:560 #9 0x00000000006f2c2b in module_destructor (module=0xf4e850) at /build/buildd/php5-5.5.3+dfsg/Zend/zend_API.c:2371 #10 0x00000000006f7eb5 in zend_hash_apply_deleter (ht=ht@entry=0xeb8ec0 <module_registry>, p=0xf4e7f0) at /build/buildd/php5-5.5.3+dfsg/Zend/zend_hash.c:650 #11 0x00000000006f96b8 in zend_hash_graceful_reverse_destroy (ht=0xeb8ec0 <module_registry>) at /build/buildd/php5-5.5.3+dfsg/Zend/zend_hash.c:687 #12 0x00000000006f155c in zend_destroy_modules () at /build/buildd/php5-5.5.3+dfsg/Zend/zend_API.c:1895 #13 0x00000000006eb79e in zend_shutdown () at /build/buildd/php5-5.5.3+dfsg/Zend/zend.c:821 #14 0x000000000068d32b in php_module_shutdown () at /build/buildd/php5-5.5.3+dfsg/main/main.c:2362 #15 0x0000000000461a76 in main (argc=2, argv=0xebb4d0) at /build/buildd/php5-5.5.3+dfsg/sapi/cli/php_cli.c:1393