From 7e69f0085e5365347bf00f4ed08d07e5f4785a96 Mon Sep 17 00:00:00 2001 From: Serhiy Storchaka Date: Mon, 8 Apr 2013 22:35:02 +0300 Subject: Close #17666: Fix reading gzip files with an extra field. --- Lib/gzip.py | 3 ++- Lib/test/test_gzip.py | 7 +++++++ Misc/NEWS | 2 ++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/Lib/gzip.py b/Lib/gzip.py index d7da02c..a1f13b4 100644 --- a/Lib/gzip.py +++ b/Lib/gzip.py @@ -302,7 +302,8 @@ class GzipFile(io.BufferedIOBase): if flag & FEXTRA: # Read & discard the extra field, if present - self._read_exact(struct.unpack("