diff options
author | Patrick Ohly <patrick.ohly@intel.com> | 2012-11-08 16:50:56 +0100 |
---|---|---|
committer | Patrick Ohly <patrick.ohly@intel.com> | 2012-12-03 17:14:47 +0100 |
commit | 1c043630c24283eece03324c67b45f9efb51c5cd (patch) | |
tree | 255abe94e23e3bf98ebb98b9ebe8d578cda97b23 /src/dbus/server/pim/folks.cpp | |
parent | a0375e0160df06cd010dab4db2135d276faa968b (diff) |
Folks: fix incorrect contact removal signals in filtered view
The filtered view did not check whether a parent's removed contact was
really part of the view before sending a removal signal for it. Was
not (and still isn't) found by unit tests because the expected signals
were sent and the tests don't wait for the superfluous additional
removal signals.
Diffstat (limited to 'src/dbus/server/pim/folks.cpp')
-rw-r--r-- | src/dbus/server/pim/folks.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dbus/server/pim/folks.cpp b/src/dbus/server/pim/folks.cpp index ec6052ee..7047da9d 100644 --- a/src/dbus/server/pim/folks.cpp +++ b/src/dbus/server/pim/folks.cpp @@ -523,7 +523,7 @@ void FilteredView::removeIndividual(int parentIndex, FolksIndividual *individual std::lower_bound(m_local2parent.begin(), m_local2parent.end(), parentIndex); - if (it != m_local2parent.end()) { + if (it != m_local2parent.end() && *it == parentIndex) { size_t index = it - m_local2parent.begin(); SE_LOG_DEBUG(NULL, NULL, "filtered view: removed at #%ld/%ld", index, m_local2parent.size()); it = m_local2parent.erase(it); |