summaryrefslogtreecommitdiffstats
path: root/Lib/zipfile.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2013-01-29 18:10:28 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2013-01-29 18:10:28 (GMT)
commit45c4375ea7da4a78e9d5dc7b79f98b7882cc7640 (patch)
tree417b552a3c2b7798011c4587208f046e330cf2e3 /Lib/zipfile.py
parenta97c57c8fdb5d91771635633f081f5150eb101c5 (diff)
downloadcpython-45c4375ea7da4a78e9d5dc7b79f98b7882cc7640.zip
cpython-45c4375ea7da4a78e9d5dc7b79f98b7882cc7640.tar.gz
cpython-45c4375ea7da4a78e9d5dc7b79f98b7882cc7640.tar.bz2
Issue #12004: Fix an internal error in PyZipFile when writing an invalid
Python file. Patch by Ben Morgan.
Diffstat (limited to 'Lib/zipfile.py')
-rw-r--r--Lib/zipfile.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/zipfile.py b/Lib/zipfile.py
index 32cf42c..a7cee72 100644
--- a/Lib/zipfile.py
+++ b/Lib/zipfile.py
@@ -1436,7 +1436,7 @@ class PyZipFile(ZipFile):
print("Compiling", file)
try:
py_compile.compile(file, doraise=True, optimize=optimize)
- except py_compile.PyCompileError as error:
+ except py_compile.PyCompileError as err:
print(err.msg)
return False
return True