From: skodak Date: Sat, 17 Jan 2009 18:47:54 +0000 (+0000) Subject: MDL-17617 - fixed regressions - missing $ch X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=7fb90df0734282111c81932a0f3a676fb7a5b7fa;p=moodle.git MDL-17617 - fixed regressions - missing $ch --- diff --git a/lib/filelib.php b/lib/filelib.php index 615ef88a97..bae9153255 100644 --- a/lib/filelib.php +++ b/lib/filelib.php @@ -344,7 +344,10 @@ function download_file_content($url, $headers=null, $postdata=null, $fullrespons // check if proxy (if used) should be bypassed for this url $proxybypass = is_proxybypass($url); - $ch = curl_init($url); + if (!$ch = curl_init($url)) { + debugging('Can not init curl.'); + return false; + } // set extra headers if (is_array($headers) ) {