Wireshark-commits: [Wireshark-commits] master-2.6 e968bd8: file: add more sanity checks to detect U
From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Tue, 03 Jul 2018 10:33:12 +0000
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=e968bd8a8499a4668cba69caa827b0758a8bf76b
Submitter: Peter Wu (peter@xxxxxxxxxxxxx)
Changed: branch: master-2.6
Repository: wireshark

Commits:

e968bd8 by Peter Wu (peter@xxxxxxxxxxxxx):

    file: add more sanity checks to detect UI/file loading issues
    
    As "cf_read" and "rescan_packets" can end up calling back to the GUI
    code, that could destroy "cf->epan" which could result in use-after-free
    crashes. While I can find most issues with ASAN, it would be even
    better to detect the destructive action in "cf_close".
    
    Change-Id: I72700a60c6786d153c2aaa8478bfdfb16a01dcda
    Ping-Bug: 10870
    Reviewed-on: https://code.wireshark.org/review/28542
    Petri-Dish: Anders Broman <a.broman58@xxxxxxxxx>
    Tested-by: Petri Dish Buildbot
    Reviewed-by: Anders Broman <a.broman58@xxxxxxxxx>
    (cherry picked from commit 2f4cdb97c7085bad56cce68dd00c9d0092a12dc9)
    Reviewed-on: https://code.wireshark.org/review/28579
    Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
    

Actions performed:

    from  c1fb20a   Qt: fix crash on opening a capture file while loading/saving another
    adds  e968bd8   file: add more sanity checks to detect UI/file loading issues


Summary of changes:
 file.c | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)