make redirections restriction in z_fetch_url() work

This commit is contained in:
zottel 2015-02-23 14:53:10 +01:00
parent 18f5e269ce
commit 8d03774666

View file

@ -109,7 +109,7 @@ function z_fetch_url($url, $binary = false, $redirects = 0, $opts = array()) {
$url_parsed = @parse_url($newurl);
if (isset($url_parsed)) {
@curl_close($ch);
return z_fetch_url($newurl,$binary,$redirects++,$opts);
return z_fetch_url($newurl,$binary,++$redirects,$opts);
}
}