From: Hannes Magnusson Date: Thu, 17 Sep 2009 11:36:29 +0000 (+0000) Subject: Fixed bug#49578 (make install-pear fails) X-Git-Tag: php-5.2.12RC1~131 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dc2f690377874114f589d14eb476bd5e4c6b5f62;p=php Fixed bug#49578 (make install-pear fails) # Apparently this script was using 5.3 functionality # Workaround would be to install 'wget' --- diff --git a/pear/fetch.php b/pear/fetch.php index 01d223392e..62c436a267 100644 --- a/pear/fetch.php +++ b/pear/fetch.php @@ -61,7 +61,12 @@ if (!isset($_ENV['http_proxy'])) { ); } -$ctx = stream_context_create($copt, array("notification" => "stream_notification_callback")); +if ($copt) { + $ctx = stream_context_create($copt); +} else { + $ctx = stream_context_create(); +} +stream_context_set_params($ctx, array("notification" => "stream_notification_callback")); $fp = fopen($argv[1], "r", false, $ctx); if (is_resource($fp) && file_put_contents($argv[2], $fp)) {