gzip feature and minor fixes

ditto