From 2d813e514020a9cf74a19e8b4ba0b98996bb24eb Mon Sep 17 00:00:00 2001 From: "Andrew M. Kuchling" Date: Mon, 6 Sep 1999 16:34:51 +0000 Subject: [PATCH] Fixed 'return EOFError' that should be 'raise EOFError', caught by Skip Montanaro's return-value patches. --- Lib/gzip.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/gzip.py b/Lib/gzip.py index 578a07bc6cc..c0aff91150c 100644 --- a/Lib/gzip.py +++ b/Lib/gzip.py @@ -182,7 +182,7 @@ class GzipFile: self.fileobj.seek(0, 2) # Seek to end of file if pos == self.fileobj.tell(): self.fileobj = None - return EOFError, "Reached EOF" + raise EOFError, "Reached EOF" else: self.fileobj.seek( pos ) # Return to original position