A workaround for CURLOPT_FOLLOWLOCATION disallowed when open_basedir is used.