[Kde-pim] Review Request: Allow building with -DQT_NO_CAST_FROM_ASCII

Kevin Krammer kevin.krammer at gmx.at
Sat Dec 19 20:06:55 GMT 2009


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

(Updated 2009-12-19 20:06:54.911284)


Review request for KDE PIM and Bertjan Broeksema.


Changes
-------

Updating diff using Ingo's suggestion (with some small modifications)
Replacing all checks for indexIn >= 0 with isMBoxSeparator() and all for index < 0 with !isMBoxSeparator().

Passing individual QRegExp instances since the indexOf method is only reentrant, not thread-safe (and internal Qt doc has a not that it should be made non-const in Qt5, so it probably isn't real const but using mutables).


Summary
-------

Replaces implicit ByteArray to QString conversion with explicit QString::fromAscii(), QLatin1String for const char* literals, QString::fromLocal8Bit() for encoded filenames.

No idea whether mbox files are always ASCII, maybe one of the other "from" methods is more appropriate


Diffs (updated)
-----

  /trunk/KDE/kdepim/runtime/resources/mbox/libmbox/mbox.cpp 1063995 
  /trunk/KDE/kdepim/runtime/resources/mbox/libmbox/tests/mboxbenchmark.cpp 1063995 
  /trunk/KDE/kdepim/runtime/resources/mbox/libmbox/tests/mboxtest.cpp 1063995 

Diff: http://reviewboard.kde.org/r/2423/diff


Testing
-------


Thanks,

Kevin

_______________________________________________
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