]> cloud.milkyroute.net Git - dolphin.git/commit
Fix possible crash in KStandardItemListWidget::paint()
authorFrank Reininghaus <frank78ac@googlemail.com>
Tue, 11 Sep 2012 17:34:23 +0000 (19:34 +0200)
committerFrank Reininghaus <frank78ac@googlemail.com>
Tue, 11 Sep 2012 17:34:23 +0000 (19:34 +0200)
commit7de641316a40ac1b570f66e5ca4109fe0b6f6702
treec5670cadc85126c3e7eff3d6006235d4e597a4fa
parentf9ba9a7236a0252a54a51b2f70a04ab13c68f85b
Fix possible crash in KStandardItemListWidget::paint()

According to the backtrace in the bug report, it is possible that
KStandardItemListWidget::paint() is called if the hash m_textInfo has
not been initialised. The widget's index must be -1 in this case, see
KStandardItemListWidget::triggerCacheRefreshing(). It looks like this
can only happen if the item is about to be removed from the view, see
KItemListView::slotItemsRemoved().

I could not reproduce the crash, so I'm not sure why exactly this
happens, but this commit should at least prevent the crash.

BUG: 306167
FIXED-IN: 4.9.2
src/kitemviews/kstandarditemlistwidget.cpp