[SCM] ktp-common-internals packaging branch, master, updated. debian/15.12.1-2-1839-gf0635e9
Maximiliano Curia
maxy at moszumanska.debian.org
Mon May 9 09:08:39 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-common-internals.git;a=commitdiff;h=ad51ed6
The following commit has been merged in the master branch:
commit ad51ed62adf49800adadb5ee4fe1b6162d6a926f
Author: Martin Klapetek <mklapetek at kde.org>
Date: Tue Feb 3 19:31:40 2015 +0100
Check for contact actually being valid before using it
When the account goes offline, the connection is invalidated and so is
the KTp::Contact, at which point it needs to used the cached data
---
kpeople/datasourceplugin/im-persons-data-source.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/kpeople/datasourceplugin/im-persons-data-source.cpp b/kpeople/datasourceplugin/im-persons-data-source.cpp
index afc2e70..c8b9432 100644
--- a/kpeople/datasourceplugin/im-persons-data-source.cpp
+++ b/kpeople/datasourceplugin/im-persons-data-source.cpp
@@ -87,7 +87,8 @@ class TelepathyContact : public KPeople::AbstractContact
public:
virtual QVariant customProperty(const QString &key) const Q_DECL_OVERRIDE
{
- if (m_contact && m_account) {
+ // Check if the contact is valid first
+ if (m_contact && m_contact->manager() && m_contact->manager()->connection() && m_account) {
if (key == AbstractContact::NameProperty)
return m_contact->alias();
else if(key == AbstractContact::GroupsProperty)
--
ktp-common-internals packaging
More information about the pkg-kde-commits
mailing list