Wireshark-commits: [Wireshark-commits] master-3.0 c753d6c: Maintain cf->state, because file cleanup

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Wed, 25 Mar 2020 21:00:25 +0000
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=c753d6c790b81dd983169d1fd769973811243d1b
Submitter: "Guy Harris <gharris@xxxxxxxxx>"
Changed: branch: master-3.0
Repository: wireshark

Commits:

c753d6c by Guy Harris (guy@xxxxxxxxxxxx):

    Maintain cf->state, because file cleanup depends on it.
    
    If we're capturing to multiple files, whenever we are told about a new
    file, we must close the old file, so we don't leak file descriptors and
    wtap structures.
    
    Have cf_close() handle the work of closing, the way it does in file.c,
    and, when we *open* a file, set the state in capture_file to
    FILE_READ_IN_PROGRESS.
    
    Bug: 16457
    Change-Id: I04a01c30571b7e3575dee5e7252a59bb1ee8abbc
    Reviewed-on: https://code.wireshark.org/review/36580
    Petri-Dish: Guy Harris <gharris@xxxxxxxxx>
    Tested-by: Petri Dish Buildbot
    Reviewed-by: Guy Harris <gharris@xxxxxxxxx>
    (cherry picked from commit 3662a69036f33a169301cfc76bd3a3c09023a68d)
    Reviewed-on: https://code.wireshark.org/review/36582
    

Actions performed:

    from  054553e   gitlab-ci: upgrade to Clang 10, drop special -Wframe-larger-than case
     add  c753d6c   Maintain cf->state, because file cleanup depends on it.


Summary of changes:
 tshark.c | 37 ++++++++++++++++++++++---------------
 1 file changed, 22 insertions(+), 15 deletions(-)