mercurial/mail.py
branchstable
changeset 46997 106402245301
parent 46992 5fa019ceb499
child 47062 f38bf44e077f
equal deleted inserted replaced
46996:8d2b62d716b0 46997:106402245301
   218         )
   218         )
   219 
   219 
   220 
   220 
   221 def _mbox(mbox, sender, recipients, msg):
   221 def _mbox(mbox, sender, recipients, msg):
   222     '''write mails to mbox'''
   222     '''write mails to mbox'''
       
   223     # TODO: use python mbox library for proper locking
   223     with open(mbox, b'ab+') as fp:
   224     with open(mbox, b'ab+') as fp:
   224         # Should be time.asctime(), but Windows prints 2-characters day
   225         # Should be time.asctime(), but Windows prints 2-characters day
   225         # of month instead of one. Make them print the same thing.
   226         # of month instead of one. Make them print the same thing.
   226         date = time.strftime('%a %b %d %H:%M:%S %Y', time.localtime())
   227         date = time.strftime('%a %b %d %H:%M:%S %Y', time.localtime())
   227         fp.write(
   228         fp.write(