[Kde-pim] Checking for valid folder names in Akonadi

Thomas McGuire mcguire at kde.org
Thu May 27 21:44:23 BST 2010


Hi, 

when creating a folder in Akonadi, we currently don't check if the name is 
valid. This can cause Bad Things, the user can use '/' in the middle or '.' at 
the start, which will confuse the IMAP and the maildir resource.

So in slotCreateCollection() of the standard action manager we should check 
this and show a nice error dialog if the folder name is invalid. Same when 
changing the folder name with the folder properties dialog. The question is: 
How? A valid file name is resource-specific, especially in the IMAP case, the 
folder seperator can apparently be server-specific, KMail 1 had methods like 
delimiterForFolder() for this.

Should we just ignore all that and simply disallow dots at the start and 
slashes? Or should we come up with some sort of D-Bus interface? That seems a 
bit overkill (especially since the client methods need to be async) to me, but 
would be the only way to do it properly.

Any opinions?

(Background: I'm trying to merge r1131250, but as usual, that turns out to be 
 a bit more complicated)

Regards,
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20100527/7f4ca4ab/attachment.sig>
-------------- next part --------------
_______________________________________________
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