Wireshark-commits: [Wireshark-commits] master 63a78d4: Use ws_fstat64() to determine the size of an
      
      
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=63a78d45bce99d9c0147d8b9c0bd0f81badc3f5f
Submitter: Guy Harris (guy@xxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark
Commits:
63a78d4 by Guy Harris (guy@xxxxxxxxxxxx):
    Use ws_fstat64() to determine the size of an open file.
    
    fseek() to the end, followed by ftell(), is a bit of an odd way to get
    the file size.  Use ws_fstat64() instead.
    
    Check that the file is a regular file, while we're at it.  This means we
    don't have to check before opening.
    
    Bug: 11268
    Change-Id: I31ee20dd5568d10541375cf97b286abfc1384d1c
    Reviewed-on: https://code.wireshark.org/review/9230
    Petri-Dish: Guy Harris <guy@xxxxxxxxxxxx>
    Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
    
Actions performed:
    from  1e511d8   ssl: test for file type before reading key file
    adds  63a78d4   Use ws_fstat64() to determine the size of an open file.
Summary of changes:
 epan/dissectors/packet-ssl-utils.c |   35 +++++++++++++++++++----------------
 wsutil/file_util.h                 |   18 ++++++++++++++++++
 wsutil/filesystem.c                |   19 -------------------
 3 files changed, 37 insertions(+), 35 deletions(-)