Fix downloading from redirected URLs

This should fix providing a URL shortener (ex: goo.gl) as long as they properly return a 3xx HTTP status code. All of these status codes require that the URL of the redirect target be given in the "Location" header of the HTTP response.