<<< Date Index >>>     <<< Thread Index >>>

<edit> and <toggle-write> / <exit>



Hi List!
On IRC we were not sure how to treat this, so maybe someone here can
help out.

Currently <edit> immediately writes the message back to the mailbox.
This is done regardless if you did <toggle-write> or <exit>.
Changing this would require a lot of rewriting according to Brendan
because the index depends on the mailbox content.
Though it would be ideal to only write the edited message back on a
<sync-mailbox> imo.
When using »mutt -R« or <change-folder-readonly> you're not allowed to
change the mailbox in any way. While <toggle-write> allows to make
changes only they are not (supposed to be) written back, <edit> is a
border case, as it will *write* to the mailbox.
Because that is done as soon as you finish editing <exit> doesn't help here
either. 
One could argue that writing the message back immediately is a safety
feature so that the edited message is not lost even though the mailbox
was read-only. 

So: Bug or feature? Is the inconsistency - writing to the mailbox even
though nothing should be written - worth the rewrite?
We could forbid <edit> while <toggle-write> but that doesn't cover the
<exit> case nor does it help when you <toggle-write> after editing a
message.

Thoughts?

Michael
-- 
linux: because a PC is a terrible thing to waste
(ksh@xxxxxxxxxxx put this on Tshirts in '93)

PGP-Key-ID: 0xDC1A44DD
Jabber:     init[0]@amessage.de