[Kde-pim] Review Request 111307: Make maildir resource handle whitespace-only header lines correctly

Frank Roscher Frank-Roscher at gmx.net
Sat Jun 29 19:14:12 BST 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/111307/
-----------------------------------------------------------

(Updated June 29, 2013, 6:14 p.m.)


Review request for KDEPIM.


Changes
-------

Laurent asked for a unit test, so the maildir unit test now is modified to test for the problem fixed by this patch.


Description
-------

Currently the maildir resource stops parsing headers when it encounters a line containing only whitespace. RFC2822 (section A.6.3., http://tools.ietf.org/html/rfc2822.html#page-48) tells us we instead must treat them like regular lines; the header only stops when a completely empty line is encountered. KMBox already does it correctly.

To be honest, it's a trivial fix - I just don't want to commit it without the regular developers giving their okay. Also, asking in advance: Should I commit to master or to 4.10? Seems like I narrowly missed the window of opportunity for the latter.


Diffs (updated)
-----

  resources/maildir/libmaildir/maildir.cpp c92b5a0 
  resources/maildir/libmaildir/tests/testmaildir.cpp 6c40b7a 

Diff: http://git.reviewboard.kde.org/r/111307/diff/


Testing (updated)
-------

Moving mails with such whitespace-only lines from one folder to the other used to cause their header information to be empty in KMail's messagelist. It works correctly now.

Also: Relevant unit test has been modified to contain a whitespace-only header line before the last normal header line. Without the fix the test fails, with it it succeeds.


Thanks,

Frank Roscher

_______________________________________________
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