# HG changeset patch # User Matt Harbison # Date 2021-04-21 03:31:36 # Node ID 1064022453016c16a6f2ce3f47a407975ee84bc9 # Parent 8d2b62d716b095507effaa8d56f87cd27ba659ab mail: add a TODO about proper mbox locking Per @nbjoerg in IRC, the mbox isn't locked correctly. Differential Revision: https://phab.mercurial-scm.org/D10505 diff --git a/mercurial/mail.py b/mercurial/mail.py --- a/mercurial/mail.py +++ b/mercurial/mail.py @@ -220,6 +220,7 @@ def _sendmail(ui, sender, recipients, ms def _mbox(mbox, sender, recipients, msg): '''write mails to mbox''' + # TODO: use python mbox library for proper locking with open(mbox, b'ab+') as fp: # Should be time.asctime(), but Windows prints 2-characters day # of month instead of one. Make them print the same thing.