Tweaked the gzip read code to use dynamic buffer sizes to balance memory use and performance.