mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-17 03:18:07 +00:00
Fix crash by replacing unsafe reverse iterator loop in EventLogList (cherry pick 23875ce1)
This commit is contained in:
parent
a0850b9967
commit
a4b38e4fd1
1 changed files with 6 additions and 3 deletions
|
|
@ -156,9 +156,12 @@ void EventLogList::displayMore() {
|
|||
}
|
||||
mCoreModelConnection->invokeToCore([this, events] {
|
||||
int currentCount = mList.count();
|
||||
for (auto it = events->end() - 1; it >= events->begin(); --it) {
|
||||
connectItem(*it);
|
||||
prepend(*it);
|
||||
if (!events->isEmpty()) {
|
||||
for (int i = events->size() - 1; i >= 0; --i) {
|
||||
const auto &ev = events->at(i);
|
||||
connectItem(ev);
|
||||
prepend(ev);
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue