Wireshark-commits: [Wireshark-commits] master 0ae1965: Qt: Fixed column issues when changing profil

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Fri, 20 Nov 2015 07:57:49 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=0ae19656e12089271ea5941bcb4663bedc337b69
Submitter: Stig Bj?rlykke (stig@xxxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark

Commits:

0ae1965 by Stig Bjørlykke (stig@xxxxxxxxxxxxx):

    Qt: Fixed column issues when changing profile.
    
    Always initialize prefs.col_list in pre_init_prefs.
    When switching to a profile without a saved 'preferences' file we
    have to initialize prefs.col_list to default values to avoid reusing
    settings from the profile we leave.
    This was introduced in 5012cf84e6d84a448171dac64c14d9c83e3d4ae6
    
    Emit columnsChanged() before preferencesChanged().
    This because columnsChanged() rebuilds cap_file_->cinfo which is used
    in preferencesChanged() to align columns (and possible other actions).
    Doing this in the wrong order will give an inconsistency and a
    heap-buffer-overflow if having different number of columns.
    
    Bug: 11493
    Change-Id: I5792dfc0ede11b9457b96f092af8da00453787b1
    Reviewed-on: https://code.wireshark.org/review/11971
    Reviewed-by: Stig Bjørlykke <stig@xxxxxxxxxxxxx>
    

Actions performed:

    from  c297df1   More spelling fixes found by lintian
    adds  0ae1965   Qt: Fixed column issues when changing profile.


Summary of changes:
 epan/prefs.c                    |   27 ++++++++++++++-------------
 ui/qt/wireshark_application.cpp |    2 +-
 2 files changed, 15 insertions(+), 14 deletions(-)