Skip to content
Commit ea6fc3cb authored by Igor Poboiko's avatar Igor Poboiko
Browse files

Don't crash if person gets removed

Summary:
Currently, right after removing a person (which i.e. removes it from personIndex), we call personChanged.
Which itself tries to access personIndex with recently removed key, which creates a default (invalid) value with such key.
In the end we obtain inconsistent (invalid) index, which leads to crash.

Test Plan:
I've noted the bug when was working on {T9595}, see [[ https://cgit.kde.org/scratch/poboiko/akonadi-kpeople-plugin.git/ | scratch repo ]] and "testab" application there.
It's sufficient to check/uncheck address books several times to crash it.
After applying this patch, it no longer crashes.

Reviewers: #frameworks, dvratil, apol, davidedmundson

Reviewed By: apol, davidedmundson

Subscribers: kde-frameworks-devel

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D15812
parent cc0899cd
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment