Review Request 124239: Fix KMimeType::Ptr::isNull implementation.

Milian Wolff mail at milianw.de
Fri Jul 3 09:19:46 UTC 2015


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

(Updated July 3, 2015, 9:19 a.m.)


Status
------

This change has been marked as submitted.


Review request for KDE Frameworks, David Faure and Laurent Montel.


Changes
-------

Submitted with commit 7ebe1d32c4704e8048dfb2579dd4f5fa2ba9dce1 by Milian Wolff to branch master.


Repository: kdelibs4support


Description
-------

The pointer is null if the contained data is a nullptr, i.e. the
negating ! was missing from the code. Also, using constData is
imo more explicit here than using operator*.

This fixes various crashes in KMail & friends that relied on isNull.


Diffs
-----

  autotests/kmimetypetest.h 0f762d38f14b6f919322d05bcdb8a74f1fc1a7e2 
  autotests/kmimetypetest.cpp c7db1cb64ec5470a5590b783d46fc97d1d2e89d8 
  src/kdecore/kmimetype.h 93bbddc8d9be8f8b6bdb3003dfbe9558d24aff9b 

Diff: https://git.reviewboard.kde.org/r/124239/diff/


Testing
-------


Thanks,

Milian Wolff

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20150703/c89b5bb6/attachment.html>


More information about the Kde-frameworks-devel mailing list