Added support for gzip output