summaryrefslogtreecommitdiffstats
path: root/Lib/pkgutil.py
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2012-01-13 17:52:16 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2012-01-13 17:52:16 (GMT)
commit5136ac0ca21a05691978df8d0650f902c8ca3463 (patch)
tree4b5569dad3f1b36f115c673602dde6ff49eae5e0 /Lib/pkgutil.py
parent1f918c1480a1566b774391bbc4ddf1d4153965a1 (diff)
downloadcpython-5136ac0ca21a05691978df8d0650f902c8ca3463.zip
cpython-5136ac0ca21a05691978df8d0650f902c8ca3463.tar.gz
cpython-5136ac0ca21a05691978df8d0650f902c8ca3463.tar.bz2
Issue #13645: pyc files now contain the size of the corresponding source
code, to avoid timestamp collisions (especially on filesystems with a low timestamp resolution) when checking for freshness of the bytecode.
Diffstat (limited to 'Lib/pkgutil.py')
-rw-r--r--Lib/pkgutil.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/pkgutil.py b/Lib/pkgutil.py
index bdea23e..ef027be 100644
--- a/Lib/pkgutil.py
+++ b/Lib/pkgutil.py
@@ -21,7 +21,7 @@ def read_code(stream):
if magic != imp.get_magic():
return None
- stream.read(4) # Skip timestamp
+ stream.read(8) # Skip timestamp and size
return marshal.load(stream)