summaryrefslogtreecommitdiffstats
path: root/Lib/mailbox.py
diff options
context:
space:
mode:
authorPetri Lehtinen <petri@digip.org>2011-11-05 07:44:59 (GMT)
committerPetri Lehtinen <petri@digip.org>2011-11-05 07:44:59 (GMT)
commit8c482ee95564f04df01fc856f313ff8c98846718 (patch)
tree8e8286ac9035b81f6a957b28b6ea331b66147e07 /Lib/mailbox.py
parent97c1bef6a4f3c522826386480c62ec27fe46301d (diff)
downloadcpython-8c482ee95564f04df01fc856f313ff8c98846718.zip
cpython-8c482ee95564f04df01fc856f313ff8c98846718.tar.gz
cpython-8c482ee95564f04df01fc856f313ff8c98846718.tar.bz2
Fix Maildir initialization so that maildir contents are read correctly.
Closes #13254.
Diffstat (limited to 'Lib/mailbox.py')
-rw-r--r--Lib/mailbox.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/Lib/mailbox.py b/Lib/mailbox.py
index e23ea8c..a677729 100644
--- a/Lib/mailbox.py
+++ b/Lib/mailbox.py
@@ -273,11 +273,9 @@ class Maildir(Mailbox):
else:
raise NoSuchMailboxError(self._path)
self._toc = {}
- self._toc_mtimes = {}
- for subdir in ('cur', 'new'):
- self._toc_mtimes[subdir] = os.path.getmtime(self._paths[subdir])
- self._last_read = time.time() # Records last time we read cur/new
- self._skewfactor = 0.1 # Adjust if os/fs clocks are skewing
+ self._toc_mtimes = {'cur': 0, 'new': 0}
+ self._last_read = 0 # Records last time we read cur/new
+ self._skewfactor = 0.1 # Adjust if os/fs clocks are skewing
def add(self, message):
"""Add message and return assigned key."""