Wireshark-commits: [Wireshark-commits] master bb81e18: Free g_ptr_array_free-related memory leaks

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Mon, 14 May 2018 13:42:19 +0000
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=bb81e1807b2a5b67905cfa1594dbbb535fe8b37e
Submitter: Peter Wu (peter@xxxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark

Commits:

bb81e18 by Peter Wu (peter@xxxxxxxxxxxxx):

    Free g_ptr_array_free-related memory leaks
    
    g_ptr_array_free(a, FALSE) returns "a->pdata". Callers that do not
    handle this will leak memory (e.g. "tshark -G plugins"). Convert other
    users to use the return value instead of direct access to "a->pdata".
    
    Change-Id: I29835477d587f5f54bf0d94cdae9f375e3da3ce3
    Reviewed-on: https://code.wireshark.org/review/27437
    Petri-Dish: Peter Wu <peter@xxxxxxxxxxxxx>
    Tested-by: Petri Dish Buildbot
    Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
    

Actions performed:

    from  d80acae   tvbuff: make tvb_bytes_exist fail with negative values
    adds  bb81e18   Free g_ptr_array_free-related memory leaks


Summary of changes:
 epan/dfilter/dfilter-macro.c         | 3 +--
 epan/expert.c                        | 2 +-
 epan/proto.c                         | 4 ++--
 epan/wslua/wslua_listener.c          | 2 +-
 plugins/epan/mate/mate_grammar.lemon | 2 +-
 plugins/epan/mate/mate_parser.l      | 2 +-
 plugins/epan/mate/mate_runtime.c     | 2 +-
 ui/qt/funnel_string_dialog.cpp       | 5 ++---
 wsutil/plugins.c                     | 2 +-
 9 files changed, 11 insertions(+), 13 deletions(-)