URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=d0da2d567078609f3610b13d6773cb7281ed9568 Submitter: Roland Knall (rkn...@gmail.com) Changed: branch: master-2.6 Repository: wireshark
Commits: d0da2d5 by Martin Kaiser (wiresh...@kaiser.cx): main window: don't keep a dangling freeze_focus_ pointer Without this fix, Wireshark crashes when the user presses Ctrl-D or selects Edit / Ignore Packet and the current focus is somewhere on the bytes view. To ignore a packet, we protect the actual ignore operation by calling main window's freeze and thaw methods. We save a pointer freeze_focus_, pointing to the widget that has the focus, and restore the focus during thaw. This causes a crash if the focused widget is part of ByteViewTab. Ignoring the packet causes a redissection, the ByteViewTab and its children are cleared. freeze_focus_ remains non-NULL but doesn't point to a valid QWdiget any more. Calling freeze_focus_->setFocus() crashes. Fix this by using a QPointer<QWdiget> for freeze_focus_. The pointer is then reset to NULL when the QWdiget that it points to goes out of scope. Change-Id: Icc1f71a9de971284c628b7815a7fc1a5cc0d5fe2 Reviewed-on: https://code.wireshark.org/review/26693 Reviewed-by: Martin Kaiser <wiresh...@kaiser.cx> Petri-Dish: Martin Kaiser <wiresh...@kaiser.cx> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <pe...@lekensteyn.nl> Reviewed-by: Roland Knall <rkn...@gmail.com> (cherry picked from commit f0fed342165145461ed88358d2fc8985d15f3745) Reviewed-on: https://code.wireshark.org/review/26816 Petri-Dish: Roland Knall <rkn...@gmail.com> Actions performed: from 088e084 Mark some fields as being in units of dBm. adds d0da2d5 main window: don't keep a dangling freeze_focus_ pointer Summary of changes: ui/qt/main_window.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) ___________________________________________________________________________ Sent via: Wireshark-commits mailing list <wireshark-commits@wireshark.org> Archives: https://www.wireshark.org/lists/wireshark-commits Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-commits mailto:wireshark-commits-requ...@wireshark.org?subject=unsubscribe