tags 396443 patch thanks This is against:
ii offlineimap 4.0.14 IMAP/Maildir synchronization and reader supp
The patch seems to work for me, might need some Python wizard and better
testing, though.
--- IMAP.py.orig 2007-01-31 06:51:04.000000000 +0100
+++ IMAP.py 2007-01-31 06:51:30.000000000 +0100
@@ -201,6 +201,12 @@
try:
if datetuple[0] < 1981:
raise ValueError
+
+ # Check for invalid date
+ datetuple_check = time.localtime(time.mktime(datetuple))
+ if datetuple[:2] != datetuple_check[:2]:
+ raise ValueError
+
# This could raise a value error if it's not a valid
# format.
date = imaplib.Time2Internaldate(datetuple)
except (ValueError, OverflowError):
signature.asc
Description: Digital signature

