On Tue, 24 Oct 2006, Michael Schaap wrote:
Here's what Thunderbird does for an MBX mailbox:
   15 list "" "Mail/foo/*"
   15 OK LIST completed
   16 close
   16 OK No messages deleted, so no update needed
   17 delete "Mail/foo"
   17 OK DELETE completed

Presumably, the reason why it did command tag 15 was to see if Mail/foo had any inferiors. But if it had listed Mail/foo, it would have see that it has the \NoInferiors attribute and thus can not have any inferiors.

while this is what it does for a MIX mailbox:
   15 list "" "Mail/foo/*"
   * LIST () "/" Mail/foo/
   15 OK LIST completed
   16 delete "Mail/foo/"
   16 NO Can't lock mailbox for delete: Mail/foo/
My guess is that Thunderbird interprets "Mail/foo/" as a sub-mailbox of "Mail/foo", and therefore thinks it needs to delete it before deleting "Mail/foo".

That's a misinterpretation on Thunderbird's part. The trailing hierarchy delimiter simply means that it could have inferiors.

I assume this is a Thunderbird bug, but wouldn't it be cleaner if imapd didn't return the trailing '/' in the first place? I realize that "Mail/foo" doesn't actually match "Mail/foo/*"...

You just gave the reason why the trailing delimiter is there; it matches the pattern and the form without the trailing delimiter does not.

But is "Mail/foo/*" actually expected to include "Mail/foo" itself?

"Mail/foo/*" doesn't include "Mail/foo", but it does include "Mail/foo/".

If "Mail/foo/" was not included, then there would be no way to distinguish the case of "Mail/foo exists but has no inferiors" from "Mail/foo does not exist".

I forget the details; but someone, once upon a time, cared very much about having that distinction because the code goes to extra effort to do it. Undoubtably, if I changed it after all these years, I get be flamed to a crisp. No thanks.

Note that that form is mentioned in the IMAP CREATE command.

It sure looks like Thunderbird does not expect it...

Since there is nothing in the IMAP specification that precludes it, Thunderbird needs to be able to handle it.

-- Mark --

http://staff.washington.edu/mrc
Science does not emerge from voting, party politics, or public debate.
Si vis pacem, para bellum.
_______________________________________________
Imap-uw mailing list
[email protected]
https://mailman1.u.washington.edu/mailman/listinfo/imap-uw

Reply via email to