Mail: Fixed double delete in PersonList.

* This should fix #12615.
This commit is contained in:
Axel Dörfler
2016-02-10 13:55:56 +01:00
parent f429e4f442
commit 1f105f6750
+2 -3
View File
@@ -1,5 +1,5 @@
/*
* Copyright 2015, Axel Dörfler, [email protected].
* Copyright 2015-2016, Axel Dörfler, [email protected].
* Distributed under the terms of the MIT License.
*/
@@ -137,9 +137,8 @@ PersonList::EntryRemoved(QueryList& source, const node_ref& nodeRef)
PersonMap::iterator found = fPersonMap.find(nodeRef);
if (found != fPersonMap.end()) {
Person* person = found->second;
fPersons.RemoveItem(person);
fPersonMap.erase(found);
delete person;
fPersons.RemoveItem(person);
}
}