Complain if the mailbox to be read does not look like a valid mbox-format
mailbox when it is a singular file.
This commit is contained in:
parent
2bfde528cd
commit
a79e730127
|
@ -4,6 +4,8 @@ Version 0.4.2 - ???
|
||||||
with the new option '--date'.
|
with the new option '--date'.
|
||||||
* Fixed a bug where archivemail would complain about messages older than
|
* Fixed a bug where archivemail would complain about messages older than
|
||||||
1970. Yes, someone had a 'Date' header with 1967 :)
|
1970. Yes, someone had a 'Date' header with 1967 :)
|
||||||
|
* Complain if the mailbox to be read does not look like a valid mbox-format
|
||||||
|
mailbox.
|
||||||
|
|
||||||
Version 0.4.1 - 21 April 2002
|
Version 0.4.1 - 21 April 2002
|
||||||
* Don't archive messages that are flagged important unless we are given the
|
* Don't archive messages that are flagged important unless we are given the
|
||||||
|
|
|
@ -924,6 +924,8 @@ def _archive_mbox(mailbox_name, final_archive_name):
|
||||||
original.procmail_lock()
|
original.procmail_lock()
|
||||||
original.exclusive_lock()
|
original.exclusive_lock()
|
||||||
msg = original.next()
|
msg = original.next()
|
||||||
|
if not msg and (original.starting_size > 0):
|
||||||
|
user_error("'%s' is not a valid mbox-format mailbox" % mailbox_name)
|
||||||
while (msg):
|
while (msg):
|
||||||
stats.another_message()
|
stats.another_message()
|
||||||
vprint("processing message '%s'" % msg.get('Message-ID'))
|
vprint("processing message '%s'" % msg.get('Message-ID'))
|
||||||
|
|
Loading…
Reference in New Issue