Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-commits: [Wireshark-commits] master-2.0 cd3a31d: Avoid recursive scan_local_interfaces op

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Sun, 25 Dec 2016 14:30:22 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=cd3a31d9976628d8733c7209635d0793f82b3801
Submitter: Michael Mann (mmann78@xxxxxxxxxxxx)
Changed: branch: master-2.0
Repository: wireshark

Commits:

cd3a31d by Mikael Kanstrup (mikael.kanstrup@xxxxxxxxx):

    Avoid recursive scan_local_interfaces operation
    
    When the local networks interfaces changes quickly or when refreshing the
    list of network interfaces there's a risk of recursive calls into
    scan_local_interfaces. The recursive calls are a result of calling
    update_cb to process UI events during function operation which in turn
    again discover a network interface change. This results in strange
    duplicate entries of network interfaces and crashes.
    
    To avoid recursive calls a check is added to stop running the function while
    already updating. This patch is really just a workaround for the problem.
    Ideally some asynchronous operation should be implemented instead to avoid
    the UI update_cb callback alltogether.
    
    Bug: 11553
    Bug: 12263
    Change-Id: I3b74d8f196677e0e261a395aff558dd9f685b538
    Reviewed-on: https://code.wireshark.org/review/14492
    Reviewed-by: Michael Mann <mmann78@xxxxxxxxxxxx>
    Petri-Dish: Michael Mann <mmann78@xxxxxxxxxxxx>
    Tested-by: Petri Dish Buildbot <buildbot-no-reply@xxxxxxxxxxxxx>
    Reviewed-by: Anders Broman <a.broman58@xxxxxxxxx>
    (cherry picked from commit 802362ee1a44d4a6494092f40e61155569ee5a6a)
    Reviewed-on: https://code.wireshark.org/review/19427
    (cherry picked from commit e7287ca66f503d6fbabeb6b5c32729ef434aa43a)
    Reviewed-on: https://code.wireshark.org/review/19428
    

Actions performed:

    from  8a6ad82   Wireshark doesn't require X11 any more.
    adds  cd3a31d   Avoid recursive scan_local_interfaces operation


Summary of changes:
 ui/iface_lists.c |   13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)