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.6 16bc36a: Lua: ensure that DATA_DIR and USER_DIR h

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Mon, 30 Apr 2018 10:34:51 +0000
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=16bc36a295810ad6c6c677505f3b6450d0e825ff
Submitter: Peter Wu (peter@xxxxxxxxxxxxx)
Changed: branch: master-2.6
Repository: wireshark

Commits:

16bc36a by Peter Wu (peter@xxxxxxxxxxxxx):

    Lua: ensure that DATA_DIR and USER_DIR have trailing slashes
    
    These directories have had trailing slashes for years and users seem to
    rely on it, so restore this assumption for backwards compatibility. The
    underlying API function (Dir.persconffile_path()) is not changed because
    trailing slashes were not documented for that function.
    
    For consistency, ensure that all Lua Dir functions return paths without
    trailing slashes.
    
    Bug: 14619
    Change-Id: Ia299864999578884b1ad1cd48f1bd883bce6879d
    Fixes: v2.5.0rc0-579-gfb052a637f ("Use g_build_filename() instead, fix indentation")
    Reviewed-on: https://code.wireshark.org/review/27166
    Reviewed-by: João Valverde <j@xxxxxx>
    Petri-Dish: João Valverde <j@xxxxxx>
    Tested-by: Petri Dish Buildbot
    Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
    (cherry picked from commit b9f915eeefc4e2db1f151cd5bd2f808711532b1c)
    Reviewed-on: https://code.wireshark.org/review/27213
    

Actions performed:

    from  16581d7   Source files should not be executable files.
    adds  16bc36a   Lua: ensure that DATA_DIR and USER_DIR have trailing slashes


Summary of changes:
 epan/wslua/template-init.lua | 5 +++--
 epan/wslua/wslua_dir.c       | 3 +--
 test/lua/dir.lua             | 5 +++++
 wsutil/filesystem.c          | 4 ++--
 4 files changed, 11 insertions(+), 6 deletions(-)