Wireshark-bugs: [Wireshark-bugs] [Bug 12580] (Qt5) after obtaining a packet trace, crashes when

Date: Sat, 02 Jul 2016 22:48:21 +0000

Comment # 2 on bug 12580 from
Yeah, the crash stops happening after amending PacketList::selectionChanged()
to avoid calling QTreeView::selectionChanged() when `selected` is empty.

I haven't had enough experience with Qt to say whether this patch is the best
way to solve this problem, but it is an improvement, at least.

I will add this diff as an attachment:

--- ui/qt/packet_list.cpp.orig    2016-06-07 12:27:47.000000000 -0600
+++ ui/qt/packet_list.cpp    2016-07-02 16:46:15.000000000 -0600
@@ -434,7 +434,9 @@
 }

 void PacketList::selectionChanged (const QItemSelection & selected, const
QItemSelection & deselected) {
-    QTreeView::selectionChanged(selected, deselected);
+    if (!selected.isEmpty()) {
+        QTreeView::selectionChanged(selected, deselected);
+    }

     if (!cap_file_) return;


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