|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-06-28 18:24 UTC] tony2001@php.net
[2006-06-28 18:43 UTC] headhunter at c-plusplus dot de
[2006-06-28 18:54 UTC] tony2001@php.net
[2006-07-06 01:00 UTC] php-bugs at lists dot php dot net
[2006-07-06 13:33 UTC] andrew dot hill at m3 dot net
[2006-07-06 13:41 UTC] tony2001@php.net
[2006-07-06 14:43 UTC] andrew dot hill at m3 dot net
[2006-07-06 15:23 UTC] headhunter at c-plusplus dot de
[2006-07-06 15:51 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 03:00:01 2025 UTC |
Description: ------------ Hello, I have found a bug which crashes PHP when using CURLOPT_FOLLOWLOCATION. This happens on certain adresses only, the one specified in the example later gives a crash. Example line: curl_setopt ($curl_handle, CURLOPT_FOLLOWLOCATION, 1); // <<< CRASH HERE I don't know my configure line exactly. Anyway, I compiled PHP by hand with--curl and --with-mysql and --with-cli. Rest is as untouched. Unique to my systems where the problems I had getting mysql5 working. It seems there is a bug in the configure Script of PHP which makes it ignore the 64bit Libraries of mysql. I had to copy /usr/lib64/mysql to /usr/lib/mysql to make compiling work. The problem is indenpendant from the php.ini, I tried different one. The default configuration also produces the crash. Reproduce code: --------------- <?php $curl_handle = curl_init(); $timeout = 10; curl_setopt ($curl_handle,CURLOPT_URL, 'www.vipnet.at'); curl_setopt ($curl_handle, CURLOPT_FOLLOWLOCATION, 1); // <<< CRASH HERE $buffer = curl_exec ($curl_handle); print_r ($buffer); ?> Expected result: ---------------- jojo@suse10064lamp:~> php bug.php *** glibc detected *** free(): invalid pointer: 0x00002aaaab7dcb00 *** Aborted Actual result: -------------- jojo@suse10064lamp:~> strace php bug.php [ snip ] open("/dev/tty", O_RDWR|O_NONBLOCK|O_NOCTTY) = 4 writev(4, [{"*** glibc detected *** ", 23}, {"free(): invalid pointer", 23}, {": 0x", 4}, {"00002aaaab7dcb00", 16}, {" ***\n", 5}], 5*** glibc detected *** free(): invalid pointer: 0x00002aaaab7dcb00 *** ) = 71 rt_sigprocmask(SIG_UNBLOCK, [ABRT], NULL, 8) = 0 tgkill(12461, 12461, SIGABRT) = 0 --- SIGABRT (Aborted) @ 0 (0) --- +++ killed by SIGABRT +++