[Kde-pim] IMAP resource: RemoveCollectionRecursiveTask::deleteNextMailbox() #287903

Martin Koller kollix at aon.at
Mon Nov 18 15:32:16 GMT 2013


On Monday 18 November 2013 09:42:02 Christian Mollekopf wrote:
> On Monday 18 November 2013 09.36:13 Christian Mollekopf wrote:
> > On Sunday 17 November 2013 16.35:03 Martin Koller wrote:
> > > I'm debugging why the imap resource can not delete an empty folder
> > > https://bugs.kde.org/show_bug.cgi?id=287903
> > > 
> > > the problem is that in RemoveCollectionRecursiveTask::deleteNextMailbox()
> > > the code tries to select all messages in the folder to set them to
> > > "deleted". However if the folder is empty, the server replies with an
> > > error
> > > "Invalid messageset" and the deletion is never done.
> > > 
> > > Why does the imap resource try to delete all mails at all ?
> > > When the folder is deleted, all mails are removed automatically.
> > 
> > Hey,
> > 
> > This seems indeed to be a pointless step. I'll check the spec, but I assume
> > you are right that we can just delete the collection.
> > 
> 
> This doesn't seem to work with subfolders though,

what does not work with subfolders ?
In my test, where I commented the "delete mails" step, I could remove a folder which had a subfolder
(If I understand the code correctly, it deletes the folders recursively, starting with the lowest in the tree (leafs first))

> so those need to be deleted 
> explicitly.

which the code does AFAIR (I'm currently in the office and don't have the code at hand)

> Obviously this also circumvents mark as deleted for the items in 
> the folder, but that's also the case if you first mark the items as deleted, 
> and then remove the folder containing the items anyways.

I did not understand this sentence.

-- 
Best regards/Schöne Grüße

Martin
()  ascii ribbon campaign - against html e-mail 
/\  www.asciiribbon.org   - against proprietary attachments

_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/



More information about the kde-pim mailing list