[trojita] [Bug 399863] segfault when repeatedly sorting

2019-04-13 Thread Walter Lapchynski
https://bugs.kde.org/show_bug.cgi?id=399863

--- Comment #6 from Walter Lapchynski  ---
Discovered a new quirk today: the smaller the window size, the more likely the
problem is to occur.

-- 
You are receiving this mail because:
You are watching all bug changes.

[trojita] [Bug 399863] segfault when repeatedly sorting

2019-03-14 Thread Thomas Lübking
https://bugs.kde.org/show_bug.cgi?id=399863

--- Comment #5 from Thomas Lübking  ---
Smells like you'd have to trigger multiple sorts within one event cycle,
possibly due to some scheduled model sanitation at cycle starts/ends?
=> Try to limit the sorting to once per event cycle (eg. w/ a flag and a
scheduled λ to clear it)

-- 
You are receiving this mail because:
You are watching all bug changes.

[trojita] [Bug 399863] segfault when repeatedly sorting

2019-03-13 Thread Walter Lapchynski
https://bugs.kde.org/show_bug.cgi?id=399863

--- Comment #4 from Walter Lapchynski  ---
Oh and I'm not super familiar with ASan but if I grok the docs correctly, a
simple -fsanitize=address to cmake should make things work and I didn't really
notice anything different.

-- 
You are receiving this mail because:
You are watching all bug changes.

[trojita] [Bug 399863] segfault when repeatedly sorting

2019-03-13 Thread Walter Lapchynski
https://bugs.kde.org/show_bug.cgi?id=399863

--- Comment #3 from Walter Lapchynski  ---
After some further testing that involved increasing the memory allocation on
the VMs I was using, I found that there seems to be some relationship between
the amount of messages required to trigger it and the amount of memory. It's
probably based more on size of messages (or mailbox/folder) rather than
individual numbers of messages from what I can tell.

Anyways, similar backtrace with b94f4307.

Thread 1 "trojita" received signal SIGSEGV, Segmentation fault.
0x73eeda82 in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5
(gdb) backs[Ktrace full
#0  0x73eeda82 in  () at /lib/x86_64-linux-gnu/libQt5Core.so.5
#1  0x73eee056 in QSortFilterProxyModel::flags(QModelIndex const&)
const () at /lib/x86_64-linux-gnu/libQt5Core.so.5
#2  0x74b3fc71 in QTreeView::isExpanded(QModelIndex const&) const () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#3  0x74b4ace5 in QTreeView::verticalScrollbarValueChanged(int) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#4  0x74ad9d5f in  () at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#5  0x73f3f5c6 in QMetaObject::activate(QObject*, int, int, void**) ()
at /lib/x86_64-linux-gnu/libQt5Core.so.5
#6  0x749778ae in QAbstractSlider::valueChanged(int) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#7  0x74977f14 in QAbstractSlider::setValue(int) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#8  0x73f3f703 in QMetaObject::activate(QObject*, int, int, void**) ()
at /lib/x86_64-linux-gnu/libQt5Core.so.5
#9  0x74887f62 in QAction::toggled(bool) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#10 0x7488a3b0 in QAction::setChecked(bool) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#11 0x7488b79a in  () at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#12 0x7488bc81 in  () at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#13 0x73f3f5c6 in QMetaObject::activate(QObject*, int, int, void**) ()
at /lib/x86_64-linux-gnu/libQt5Core.so.5
#14 0x74889a2e in QActionPrivate::sendDataChanged() () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#15 0x7488a397 in QAction::setChecked(bool) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#16 0x73f3f703 in QMetaObject::activate(QObject*, int, int, void**) ()
at /lib/x86_64-linux-gnu/libQt5Core.so.5
#17 0x5578451c in
Imap::Mailbox::PrettyMsgListModel::sortingPreferenceChanged(int, Qt::SortOrder)
(this=this@entry=0x55c80630, _t1=, _t1@entry=2,
_t2=, _t2@entry=Qt::AscendingOrder) at
/home/lubuntu/trojita/_build/Imap_autogen/I7YDGANZM2/moc_PrettyMsgListModel.cpp:131
_a = {0x0, 0x7fffca2c, 0x7fffca28}
#18 0x55735ff3 in Imap::Mailbox::PrettyMsgListModel::sort(int,
Qt::SortOrder) (this=0x55c80630, column=2, order=Qt::AscendingOrder) at
/home/lubuntu/trojita/src/Imap/Model/PrettyMsgListModel.cpp:244
threadingModel = 
criterium = Imap::Mailbox::ThreadingMsgListModel::SORT_FROM
willSort = true
#19 0x73f3f5c6 in QMetaObject::activate(QObject*, int, int, void**) ()
at /lib/x86_64-linux-gnu/libQt5Core.so.5
#20 0x74ae536f in QHeaderView::sortIndicatorChanged(int, Qt::SortOrder)
() at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#21 0x74aee975 in  () at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#22 0x74aeebfa in QHeaderView::mouseReleaseEvent(QMouseEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#23 0x748cc748 in QWidget::event(QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#24 0x7496ff4e in QFrame::event(QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#25 0x74ae149b in QAbstractItemView::viewportEvent(QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#26 0x74af038b in QHeaderView::viewportEvent(QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#27 0x73f1618b in
QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Core.so.5
#28 0x7488e481 in QApplicationPrivate::notify_helper(QObject*, QEvent*)
() at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#29 0x74895d08 in QApplication::notify(QObject*, QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#30 0x73f16479 in QCoreApplication::notifyInternal2(QObject*, QEvent*)
() at /lib/x86_64-linux-gnu/libQt5Core.so.5
#31 0x74895019 in QApplicationPrivate::sendMouseEvent(QWidget*,
QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer&, bool) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#32 0x748e7264 in  () at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#33 0x748e9dee in  () at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#34 0x7488e491 in QApplicationPrivate::notify_helper(QObject*, QEvent*)
() at /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#35 0x74895ac0 in QApplication::notify(QObject*, QEvent*) () at
/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#36 

[trojita] [Bug 399863] segfault when repeatedly sorting

2019-03-13 Thread Walter Lapchynski
https://bugs.kde.org/show_bug.cgi?id=399863

--- Comment #2 from Walter Lapchynski  ---
One piece of information I failed to include: it seems to require at least 10
messages.

-- 
You are receiving this mail because:
You are watching all bug changes.

[trojita] [Bug 399863] segfault when repeatedly sorting

2018-11-12 Thread Jan Kundrát
https://bugs.kde.org/show_bug.cgi?id=399863

Jan Kundrát  changed:

   What|Removed |Added

 Status|REPORTED|CONFIRMED
 Ever confirmed|0   |1

--- Comment #1 from Jan Kundrát  ---
I was able to get a backtrace after a long series of random clicking. This is
with a random and pretty old snapshot of Qt.

Thread 1 "trojita" received signal SIGSEGV, Segmentation fault.
0x72625fa9 in QSortFilterProxyModelPrivate::proxy_to_source(QModelIndex
const&) const () at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/itemmodels/qsortfilterproxymodel.cpp:430
430
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/itemmodels/qsortfilterproxymodel.cpp:
No such file or directory.
(gdb) bt
#0  0x72625fa9 in
QSortFilterProxyModelPrivate::proxy_to_source(QModelIndex const&) const () at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/itemmodels/qsortfilterproxymodel.cpp:430
#1  0x72625fe1 in QSortFilterProxyModel::mapToSource (this=, proxyIndex=...) at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/itemmodels/qsortfilterproxymodel.cpp:2849
#2  0x72624ee5 in QSortFilterProxyModel::flags (this=,
index=...) at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/itemmodels/qsortfilterproxymodel.cpp:2329
#3  0x735a4211 in QModelIndex::flags (this=0x7fffbcc0) at
../../include/QtCore/../../../qtwidgets-5.11./src/corelib/itemmodels/qabstractitemmodel.h:458
#4  QTreeViewPrivate::isIndexExpanded (idx=..., this=0x55c01620) at
../../include/QtWidgets/5.11.0/QtWidgets/private/../../../../../../qtwidgets-5.11./src/widgets/itemviews/qtreeview_p.h:214
#5  QTreeView::isExpanded (this=this@entry=0x55bfbe70, index=...) at
/var/tmp/portage/dev-qt/qtwidgets-5.11./work/qtwidgets-5.11./src/widgets/itemviews/qtreeview.cpp:841
#6  0x735af1da in QTreeView::verticalScrollbarValueChanged
(this=0x55bfbe70, value=33) at
/var/tmp/portage/dev-qt/qtwidgets-5.11./work/qtwidgets-5.11./src/widgets/itemviews/qtreeview.cpp:4020
#7  0x7353e42f in QAbstractItemView::qt_static_metacall (_o=, _c=, _id=, _a=) at
.moc/moc_qabstractitemview.cpp:422
#8  0x7267106b in QMetaObject::activate(QObject*, int, int, void**) ()
at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/kernel/qobject.cpp:3771
#9  0x72671677 in QMetaObject::activate
(sender=sender@entry=0x55c021d0, m=m@entry=0x739be960
,
local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7fffbe50)
at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/kernel/qobject.cpp:3633
#10 0x733de36e in QAbstractSlider::valueChanged
(this=this@entry=0x55c021d0, _t1=, _t1@entry=33) at
.moc/moc_qabstractslider.cpp:304
#11 0x733de9d4 in QAbstractSlider::setValue (this=0x55c021d0,
value=33) at
/var/tmp/portage/dev-qt/qtwidgets-5.11./work/qtwidgets-5.11./src/widgets/widgets/qabstractslider.cpp:546
#12 0x726711af in QtPrivate::QSlotObjectBase::call (a=0x7fffbff0,
r=0x7fffd3c0, this=0x55d6f7a0) at
../../include/QtCore/../../../qtcore-5.11./src/corelib/kernel/qobjectdefs_impl.h:376
#13 QMetaObject::activate(QObject*, int, int, void**) () at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/kernel/qobject.cpp:3754
#14 0x72671677 in QMetaObject::activate
(sender=sender@entry=0x55da9910, m=m@entry=0x739b92e0
, local_signal_index=local_signal_index@entry=4,
argv=argv@entry=0x7fffbff0)
at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/kernel/qobject.cpp:3633
#15 0x732f0c12 in QAction::toggled (this=this@entry=0x55da9910,
_t1=, _t1@entry=false) at .moc/moc_qaction.cpp:389
#16 0x732f300e in QAction::setChecked (this=0x55da9910,
b=b@entry=false) at
/var/tmp/portage/dev-qt/qtwidgets-5.11./work/qtwidgets-5.11./src/widgets/kernel/qaction.cpp:983
#17 0x732f43da in QActionGroupPrivate::_q_actionChanged
(this=0x55d9ec40) at
/var/tmp/portage/dev-qt/qtwidgets-5.11./work/qtwidgets-5.11./src/widgets/kernel/qactiongroup.cpp:77
#18 0x732f48c1 in QActionGroup::qt_static_metacall (_o=,
_c=, _id=, _a=)
at
/var/tmp/portage/dev-qt/qtwidgets-5.11./work/qtwidgets-5.11./src/widgets/kernel/qactiongroup.h:56
#19 0x7267106b in QMetaObject::activate(QObject*, int, int, void**) ()
at
/var/tmp/portage/dev-qt/qtcore-5.11./work/qtcore-5.11./src/corelib/kernel/qobject.cpp:3771
#20 0x72671677 in QMetaObject::activate
(sender=sender@entry=0x55d9d530, m=m@entry=0x739b92e0
, local_signal_index=local_signal_index@entry=0,
argv=argv@entry=0x0)
at