[SCM] ktp-accounts-kcm packaging branch, master, updated. debian/15.12.1-1-1157-gc4589c5
Maximiliano Curia
maxy at moszumanska.debian.org
Fri May 27 23:59:25 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-accounts-kcm.git;a=commitdiff;h=86b55e6
The following commit has been merged in the master branch:
commit 86b55e6285e0596098ebd5f53418e981f55f0fbe
Author: Rohan Garg <rohangarg at kubuntu.org>
Date: Thu Mar 31 02:40:22 2011 +0530
Don't crash if available profile list is empty
Reviewed By : David Edmundson and Keith Rusler
---
src/KCMTelepathyAccounts/profile-list-model.cpp | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/src/KCMTelepathyAccounts/profile-list-model.cpp b/src/KCMTelepathyAccounts/profile-list-model.cpp
index f0f46d4..f3b5065 100644
--- a/src/KCMTelepathyAccounts/profile-list-model.cpp
+++ b/src/KCMTelepathyAccounts/profile-list-model.cpp
@@ -94,10 +94,16 @@ void ProfileListModel::setProfileManager(Tp::ProfileManagerPtr profileManager)
}
insertItems.append(new ProfileItem(profile, this));
}
-
- beginInsertRows(QModelIndex(), 0, insertItems.size()-1);
- m_profileItems.append(insertItems);
- endInsertRows();
+
+ if( insertItems.size() > 0 )
+ {
+ beginInsertRows(QModelIndex(), 0, insertItems.size()-1);
+ m_profileItems.append(insertItems);
+ endInsertRows();
+ }
+ else
+ return;
+
}
ProfileItem *ProfileListModel::itemForIndex(const QModelIndex &index) const
--
ktp-accounts-kcm packaging
More information about the pkg-kde-commits
mailing list