commit | ae8c078dbb93db3af982b7b42382e956af663185 | [log] [tgz] |
---|---|---|
author | Benjamin Peterson <benjamin@python.org> | Thu Jan 21 22:04:04 2016 -0800 |
committer | Benjamin Peterson <benjamin@python.org> | Thu Jan 21 22:04:04 2016 -0800 |
tree | 825f95658a318a8073d78a4dcd3ac7f3cc1e0d4b | |
parent | cbde4a6924296504447928520ab8fad9bc860b64 [diff] | |
parent | d52513cb222174df834ea81e61037899248e312c [diff] |
merge 3.5
diff --git a/Modules/zipimport.c b/Modules/zipimport.c index 78cf398..82e640b 100644 --- a/Modules/zipimport.c +++ b/Modules/zipimport.c
@@ -1091,6 +1091,10 @@ &date, &crc)) { return NULL; } + if (data_size < 0) { + PyErr_Format(ZipImportError, "negative data size"); + return NULL; + } fp = _Py_fopen_obj(archive, "rb"); if (!fp)