luislavena/mini_portile — pull request #30 by knu (2014-04-01 10:28:53+00:00)
Title: Specify Accept-Encoding to make sure a raw file content is downloaded.

When a response header has a Content-Encoding header Net::HTTP
automatically decodes the content unless Accept-Encoding is explicitly
given, and some problematic server like zlib.net wrongly adds a header
"Content-Encoding: gzip" along with "Content-Type: x-gzip" for gzip'd
tar files (*.tar.gz). This combination leads to an unfortunate result
that the saved content of a downloaded gzip'd tarball is already
gunzip'd and the following extraction thus fails.