[Kde-pim] Review Request: Akonadi: Fix handling of CR and LF in collection attributes
Volker Krause
vkrause at kde.org
Sat Jun 20 21:17:09 BST 2009
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.kde.org/r/865/#review1356
-----------------------------------------------------------
Ship it!
Looks good to me.
- Volker
On 2009-06-20 03:55:38, Frank Osterfeld wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.kde.org/r/865/
> -----------------------------------------------------------
>
> (Updated 2009-06-20 03:55:38)
>
>
> Review request for KDE PIM.
>
>
> Summary
> -------
>
> When creating a collection with CR and/or LF in attribute values, the CollectionCreateJob gets stuck forever.
> That's because ImapParser doesn't quote CR and LF at all when creating the quoted string for the attribute value.
> According to [1], CR and LF are not allowed inside a quoted string.
> This patch fixes this by escaping LF as "\n" and CR as "\r" in ImapParser::quote() and resolving them again in ImapParser::parseQuotedString and ImapStreamParser;:parseQuotedString().
>
> [1] http://tools.ietf.org/html/rfc3501
>
>
> Diffs
> -----
>
> trunk/kdesupport/akonadi/libs/imapparser.cpp 983998
> trunk/kdesupport/akonadi/server/src/imapstreamparser.cpp 983998
>
> Diff: http://reviewboard.kde.org/r/865/diff
>
>
> Testing
> -------
>
> Added tests for CR, LF to kdepimlibs/akonadi/tests/collectionattributetest.cpp .
> All tests pass after my modifications.
> Successfully imported a RSS feed list containing LF in feed descriptions (which end up in a collection attribute and triggered this in the first place).
>
>
> Thanks,
>
> Frank
>
>
_______________________________________________
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