Title: _mboxMMDF#get_message should delegate to get_bytes
Type: enhancement Stage:
Components: email Versions:
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: barry, bpoaugust, r.david.murray
Priority: normal Keywords:

Created on 2016-12-10 17:35 by bpoaugust, last changed 2016-12-11 03:00 by bpoaugust.

Messages (2)
msg282863 - (view) Author: (bpoaugust) Date: 2016-12-10 17:35
At present both _mboxMMDF#get_message and get_bytes read the file directly.

However the code in get_bytes duplicates some of the code in get_message. get_message should be recoded to use get_bytes.

It would then be possible to override get_bytes (which is also used by get_string) in order to transform the input stream e.g. to unmangle '>From ' lines.

But in any case it makes sense to reuse the code - DRY
msg282896 - (view) Author: (bpoaugust) Date: 2016-12-11 03:00
On further investigation it sppears that overriding the get_bytes function does not help with unmangling >From.
However it would still be worth re-using the code.
Date User Action Args
2016-12-11 03:00:15bpoaugustsetmessages: + msg282896
2016-12-10 17:35:36bpoaugustcreate