|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-06-09 09:01 UTC] johannes@php.net
[2007-06-17 01:00 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Nov 05 05:00:01 2025 UTC |
Description: ------------ Using curl_init() after using the fsockopen calls produce a segmentation fault into apache The script i've attached always reproduces the problem on my service provider server (just set the var to some working location) Cya Reproduce code: --------------- $file = fsockopen ($site, $port, $errno, $errstr,6); if (!$file) { echo "<sockmessage>$site, $port $errstr ($errno)</sockmessage>\n"; @fclose ($file); } else { socket_set_timeout($file,1); fputs ($file, "\n"); @fclose ($file); } $crl = curl_init(); $timeout = 2; curl_setopt ($crl, CURLOPT_URL,$url); curl_setopt ($crl, CURLOPT_RETURNTRANSFER, 1); curl_setopt ($crl, CURLOPT_CONNECTTIMEOUT, $timeout); $ret = curl_exec($crl); curl_close($crl); echo "$ret"; Expected result: ---------------- The contents of the url curl opened :) Actual result: -------------- Apache goes segfault