summaryrefslogtreecommitdiffstats
path: root/Lib/py_compile.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1998-10-07 14:06:03 (GMT)
committerGuido van Rossum <guido@python.org>1998-10-07 14:06:03 (GMT)
commit56440a58f7a9e4aff1877c86772c846093ea5fd3 (patch)
tree6811c357951853df72a5d69bd84a92cd2fd7ec66 /Lib/py_compile.py
parent2ccaf6f2f9d62828b3ea34720de27e758a673e17 (diff)
downloadcpython-56440a58f7a9e4aff1877c86772c846093ea5fd3.zip
cpython-56440a58f7a9e4aff1877c86772c846093ea5fd3.tar.gz
cpython-56440a58f7a9e4aff1877c86772c846093ea5fd3.tar.bz2
Fix two bugs in the fstat() line, reported by Fredruk Lundh.
Diffstat (limited to 'Lib/py_compile.py')
-rw-r--r--Lib/py_compile.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/py_compile.py b/Lib/py_compile.py
index a6d03d7..e1d0d70 100644
--- a/Lib/py_compile.py
+++ b/Lib/py_compile.py
@@ -44,7 +44,7 @@ def compile(file, cfile=None, dfile=None):
import os, marshal, __builtin__
f = open(file)
try:
- timestamp = os.fstat(file.fileno())
+ timestamp = long(os.fstat(f.fileno())[8])
except AttributeError:
timestamp = long(os.stat(file)[8])
codestring = f.read()