Summary: | KMail2 crashed while manipulating folders [assert, indexIsValid, KSelectionProxyModelPrivate::createTopLevelIndex, KSelectionProxyModel::index, Akonadi::EntityMimeTypeFilterModel::filterAcceptsRow] | ||
---|---|---|---|
Product: | [Applications] kmail2 | Reporter: | Andrey Borzenkov <arvidjaar> |
Component: | general | Assignee: | kdepim bugs <kdepim-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | alex.merry, andresbajotierra, cryvo, faure, ht990332, montel, steveire, winter |
Priority: | NOR | ||
Version: | Git (master) | ||
Target Milestone: | --- | ||
Platform: | Mandriva RPMs | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Andrey Borzenkov
2010-10-03 11:14:49 UTC
From bug 255828: - What I was doing when the application crashed: KMail had fully expanded one of my IMAP accounts (so all the folders in the treeview were expanded - it does this frequently), so I was going through, rapidly closing them (closing most of the subfolders, then closing the top one). As I clicked on one of the arrows to collapse a top-level folder, KMail crashed. From bug 253131: -- Information about the crash: What I was doing when the application crashed: - launch KMail - select (mouse-click) folder "Local Copies of ..." - select multiplie folders (mouse-click+Shift) *** Bug 253131 has been marked as a duplicate of this bug. *** *** Bug 255828 has been marked as a duplicate of this bug. *** Git commit 0f7cf4634300a9d5af3c1498a3efd6320fd590fb by Stephen Kelly. Committed on 26/04/2011 at 01:22. Pushed by skelly into branch 'KDE/4.6'. While processing changes in the source, don't process selections. Because the proxy hadn't processed the rowsInserted or rowsRemoved signal yet, it was creating corrupt internal data. Possible crash fix. Please retest. BUG: 253108 M +23 -0 kdeui/itemviews/kselectionproxymodel.cpp http://commits.kde.org/kdelibs/0f7cf4634300a9d5af3c1498a3efd6320fd590fb Git commit 714275673d8e3d98377b4d72667b05df9c4c3bc5 by Stephen Kelly. Committed on 26/04/2011 at 01:22. Pushed by skelly into branch 'master'. While processing changes in the source, don't process selections. Because the proxy hadn't processed the rowsInserted or rowsRemoved signal yet, it was creating corrupt internal data. Possible crash fix. Please retest. BUG: 253108 (cherry picked from commit 0f7cf4634300a9d5af3c1498a3efd6320fd590fb) M +23 -0 kdeui/itemviews/kselectionproxymodel.cpp http://commits.kde.org/kdelibs/714275673d8e3d98377b4d72667b05df9c4c3bc5 Reopen. The crash is still valid in master: #6 0x00007f36085d5e3f in qt_message(QtMsgType, const char *, typedef __va_list_tag __va_list_tag *) (msgType=QtFatalMsg, msg= 0x7f3608741428 "ASSERT: \"%s\" in file %s, line %d", ap=0x7fff59a4f748) at global/qglobal.cpp:2298 #7 0x00007f36085d5fe4 in qFatal (msg=<optimized out>) at global/qglobal.cpp:2481 #8 0x00007f36085d602a in qt_assert (assertion=<optimized out>, file=<optimized out>, line=<optimized out>) at global/qglobal.cpp:1999 #9 0x00007f360a6b2d48 in indexIsValid (startWithChildTrees=true, row=71, rootIndexList=..., mappedFirstChildren=...) at /kde/src/kdelibs/kdeui/itemviews/kselectionproxymodel.cpp:1283 #10 0x00007f360a6b2dc7 in KSelectionProxyModelPrivate::createTopLevelIndex (this=0x11298b80, row=71, column=0) at /kde/src/kdelibs/kdeui/itemviews/kselectionproxymodel.cpp:1292 #11 0x00007f360a6b7df8 in KSelectionProxyModel::index (this=0x1e34520, row=71, column=0, parent=...) at /kde/src/kdelibs/kdeui/itemviews/kselectionproxymodel.cpp:2209 #12 0x00007f36042f0518 in Akonadi::EntityMimeTypeFilterModel::filterAcceptsRow (this=0xba25780, sourceRow=71, sourceParent=...) at /kde/src/pim/kdepimlibs/akonadi/entitymimetypefiltermodel.cpp:103 #13 0x00007f36091c0e86 in QSortFilterProxyModelPrivate::source_items_inserted (this=0x1d87330, source_parent=..., start=<optimized out>, end=92, orient=Qt::Vertical) at itemviews/qsortfilterproxymodel.cpp:769 #14 0x00007f36091c116f in QSortFilterProxyModelPrivate::_q_sourceRowsInserted (this=0x1d87330, source_parent=..., start=<optimized out>, end=<optimized out>) at itemviews/qsortfilterproxymodel.cpp:1280 ---Type <return> to continue, or q <return> to quit--- #15 0x00007f36086f1751 in QMetaObject::activate (sender=0x1e34520, m=<optimized out>, local_signal_index=<optimized out>, argv=0x7fff59a4fc70) at kernel/qobject.cpp:3556 #16 0x00007f360873dfa4 in QAbstractItemModel::rowsInserted (this=<optimized out>, _t1=..., _t2=70, _t3=92) at .moc/release-shared/moc_qabstractitemmodel.cpp:197 #17 0x00007f36086d790d in QAbstractItemModel::endInsertRows (this=0x1e34520) at kernel/qabstractitemmodel.cpp:2433 #18 0x00007f360a6b69be in KSelectionProxyModelPrivate::insertSelectionIntoProxy (this=0x11298b80, selection=...) at /kde/src/kdelibs/kdeui/itemviews/kselectionproxymodel.cpp:1955 #19 0x00007f360a6b63a9 in KSelectionProxyModelPrivate::selectionChanged (this=0x11298b80, _selected=..., _deselected=...) at /kde/src/kdelibs/kdeui/itemviews/kselectionproxymodel.cpp:1889 #20 0x00007f360a6ba402 in KSelectionProxyModel::qt_static_metacall (_o=0x1e34520, _c=QMetaObject::InvokeMetaMethod, _id=15, _a=0x7fff59a502c0) at /kde/build/kdelibs/kdeui/moc_kselectionproxymodel.cpp:111 #21 0x00007f36086f1751 in QMetaObject::activate (sender=0xcdd260, m=<optimized out>, local_signal_index=<optimized out>, argv=0x7fff59a502c0) at kernel/qobject.cpp:3556 #22 0x00007f360918b997 in QItemSelectionModel::selectionChanged (this=<optimized out>, _t1=..., _t2=...) at .moc/release-shared/moc_qitemselectionmodel.cpp:166 #23 0x00007f36091913d1 in QItemSelectionModel::emitSelectionChanged (this=0xcdd260, newSelection=..., oldSelection=...) at itemviews/qitemselectionmodel.cpp:1600 #24 0x00007f3609192781 in QItemSelectionModel::select (this=0xcdd260, selection=..., command=...) at itemviews/qitemselectionmodel.cpp:1110 #25 0x00007f3603690cb4 in MessageList::Pane::Private::onSelectionChanged (this=0xc71a10, selected=..., deselected=...) at /kde/src/pim/kdepim/messagelist/pane.cpp:393 #26 0x00007f36036938f6 in MessageList::Pane::qt_static_metacall (_o=0xcd7540, _c=QMetaObject::InvokeMetaMethod, _id=9, _a=0x7fff59a508e0) at /kde/build/pim/kdepim/messagelist/pane.moc:95 #27 0x00007f36086f1751 in QMetaObject::activate (sender=0xbb62a0, m=<optimized out>, local_signal_index=<optimized out>, argv=0x7fff59a508e0) at kernel/qobject.cpp:3556 #28 0x00007f360918b997 in QItemSelectionModel::selectionChanged (this=<optimized out>, _t1=..., _t2=...) at .moc/release-shared/moc_qitemselectionmodel.cpp:166 #29 0x00007f36091913d1 in QItemSelectionModel::emitSelectionChanged (this=0xbb62a0, newSelection=..., oldSelection=...) at itemviews/qitemselectionmodel.cpp:1600 #30 0x00007f3609192781 in QItemSelectionModel::select (this=0xbb62a0, selection=..., command=...) at itemviews/qitemselectionmodel.cpp:1110 ---Type <return> to continue, or q <return> to quit--- #31 0x00007f360917d015 in QTreeViewPrivate::select (this=0xbbf310, topIndex=..., bottomIndex=..., command=...) at itemviews/qtreeview.cpp:3703 #32 0x00007f360917dd52 in QTreeView::setSelection (this=<optimized out>, rect=..., command=...) at itemviews/qtreeview.cpp:2317 #33 0x00007f360913a32a in QAbstractItemView::mousePressEvent (this=0x6ba520, event=<optimized out>) at itemviews/qabstractitemview.cpp:1690 #34 0x00007f36032338be in MailCommon::FolderTreeView::mousePressEvent (this=0x6ba520, e=0x7fff59a51eb0) at /kde/src/pim/kdepim/mailcommon/foldertreeview.cpp:555 #35 0x00007f3608c63879 in QWidget::event (this=0x6ba520, event=0x7fff59a51eb0) at kernel/qwidget.cpp:8357 #36 0x00007f360901f5e6 in QFrame::event (this=0x6ba520, e=0x7fff59a51eb0) at widgets/qframe.cpp:557 #37 0x00007f3609133abb in QAbstractItemView::viewportEvent (this=0x6ba520, event=0x7fff59a51eb0) at itemviews/qabstractitemview.cpp:1644 #38 0x00007f360917b5d5 in QTreeView::viewportEvent (this=0x6ba520, event=0x7fff59a51eb0) at itemviews/qtreeview.cpp:1257 #39 0x00007f36086dda18 in QCoreApplicationPrivate::sendThroughObjectEventFilters (this=<optimized out>, receiver=0xbb93a0, event=0x7fff59a51eb0) at kernel/qcoreapplication.cpp:986 #40 0x00007f3608c12e4f in notify_helper (e=0x7fff59a51eb0, receiver=0xbb93a0, this=0x77c3d0) at kernel/qapplication.cpp:4546 #41 QApplicationPrivate::notify_helper (this=0x77c3d0, receiver=0xbb93a0, e=0x7fff59a51eb0) at kernel/qapplication.cpp:4522 #42 0x00007f3608c185d3 in QApplication::notify (this=<optimized out>, receiver=0xbb93a0, e=0x7fff59a51eb0) at kernel/qapplication.cpp:4093 #43 0x00007f360a6ce4e3 in KApplication::notify (this=0x7fff59a52b40, receiver=0xbb93a0, event=0x7fff59a51eb0) at /kde/src/kdelibs/kdeui/kernel/kapplication.cpp:311 #44 0x00007f36086dd88c in QCoreApplication::notifyInternal (this=0x7fff59a52b40, receiver=0xbb93a0, event=0x7fff59a51eb0) at kernel/qcoreapplication.cpp:876 #45 0x00007f3608c13e52 in sendEvent (event=<optimized out>, receiver=<optimized out>) at ../../src/corelib/kernel/qcoreapplication.h:231 #46 QApplicationPrivate::sendMouseEvent (receiver=0xbb93a0, event=0x7fff59a51eb0, alienWidget=0xbb93a0, nativeWidget=0x66d710, buttonDown=0xbb93a0, lastMouseReceiver=..., spontaneous=true) at kernel/qapplication.cpp:3161 #47 0x00007f3608c8fc05 in QETWidget::translateMouseEvent (this=0x66d710, event=<optimized out>) at kernel/qapplication_x11.cpp:4505 #48 0x00007f3608c8eaca in QApplication::x11ProcessEvent (this=0x7fff59a52b40, event=0x7fff59a52780) at kernel/qapplication_x11.cpp:3631 ---Type <return> to continue, or q <return> to quit--- #49 0x00007f3608cb704a in QEventDispatcherX11::processEvents (this=0x60da70, flags=...) at kernel/qeventdispatcher_x11.cpp:132 #50 0x00007f36086dc672 in QEventLoop::processEvents (this=<optimized out>, flags=...) at kernel/qeventloop.cpp:149 #51 0x00007f36086dc8c7 in QEventLoop::exec (this=0x7fff59a529d0, flags=...) at kernel/qeventloop.cpp:204 #52 0x00007f36086e1425 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1148 #53 0x0000000000403855 in main (argc=1, argv=0x7fff59a52cb8) at /kde/src/pim/kdepim/kmail/main.cpp:145 Steps to reproduce : - imap account --- Inbox ----- Sub-Folder 1 ----- Sub-Folder 2 [...] ----- Sub-Folder X Click on sub-folder X, shift-click on inbox. yep, I can crash using the same steps shown in comment 7 david had a patch for testing against column 0... I wonder if that will help here? adding David. David, you had a patch that might fix this, didn't you? I could not reproduce this. Does it happen every time? Is it something that newly re-appeared recently? Can someone who can reproduce it give me a smaller testcase than kmail? Yes, it's 100% reproducible here. With the same scheme: - imap account --- Inbox ----- Sub-Folder 1 ----- Sub-Folder 2 ----- Sub-Folder 3 ----- Sub-Folder 4 ----- Sub-Folder X * selecting Sub-Folder 4 then Sub-Folder 2 works * Selecting Sub-Folder [1-4] then Inbox works * Only selecting the last subfolder then Inbox triggers the crash (X=29 in my case) Thanks. I do still need more information though. I can't reproduce it. Is this something that re-appeared recently? Is this something that only appeared after a Qt upgrade? Does it happen with all Akonadi applications? Can you add some debug output above the assert with information relevant to the assert? What is actually the inequality that is causing the assert to be hit? Can you create a smaller testcase? > Is this something that re-appeared recently? no, it's been around for some time > Is this something that only appeared after a Qt upgrade? no, happens for me with Qt4.7.4 > Can you add some debug output above the assert with information relevant to the assert? today krop some experiments and showed this <krop> (gdb) p m_includeAllSelected [10:17] <krop> $1 = true [10:17] <krop> (gdb) p sourceTopLeft [10:17] <krop> $2 = {r = 7, c = 0, p = 0x104c540, m = 0x826f50} [10:17] <krop> (gdb) p sourceBottomLeft [10:17] <krop> $3 = {r = 4, c = 0, p = 0x1058fb0, m = 0x826f50} I noticed that the rows in the bottom is less than the row of the top. does that matter? If I do this on line 1645 if(sourceBottomLeft.row() <= sourceTopLeft.row()) return; then I no longer get into the assert. does any of this info help? Those gdb prints were for another report (bug 275752) *** Bug 290057 has been marked as a duplicate of this bug. *** Could you verify with last kdepimlibs+kdepim+kdelibs please ? We fixed a lot of bug during akademy 2012 no more info reported. no more crashes reported in the past few months. => resolving |