From 46d565111e6c7c3f84761e9025e7e933ad31c33f Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Sat, 1 Jul 2000 10:52:49 +0000 Subject: [PATCH] getatime() returned the mtime instead of the atime. Similar to an old bug in ntpath.py. --- Lib/dospath.py | 2 +- Lib/macpath.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/dospath.py b/Lib/dospath.py index 4e4be565188..98efe6751f5 100644 --- a/Lib/dospath.py +++ b/Lib/dospath.py @@ -131,7 +131,7 @@ def getmtime(filename): def getatime(filename): """Return the last access time of a file, reported by os.stat().""" st = os.stat(filename) - return st[stat.ST_MTIME] + return st[stat.ST_ATIME] def islink(path): diff --git a/Lib/macpath.py b/Lib/macpath.py index 3e36f79dd89..464bdd0f55c 100644 --- a/Lib/macpath.py +++ b/Lib/macpath.py @@ -114,7 +114,7 @@ def getmtime(filename): def getatime(filename): """Return the last access time of a file, reported by os.stat().""" st = os.stat(filename) - return st[ST_MTIME] + return st[ST_ATIME] def islink(s):