Wireshark-commits: [Wireshark-commits] master a36db75: plugins/mate: fix some memleaks

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Mon, 29 Jun 2015 22:56:27 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=a36db750e4b9002c91899c7a9b774401f2de1b81
Submitter: Peter Wu (peter@xxxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark

Commits:

a36db75 by Peter Wu (peter@xxxxxxxxxxxxx):

    plugins/mate: fix some memleaks
    
    Fixes about 5kB leaks in 500+ allocations.
    
    There are still some other remaining (and not fixed in this patch
    because it is hard to track them):
    
     - The g_strdup'ed memory via MATE_PARSE for some types (cannot simply
       g_free after use, it is still needed in some cases).
     - cfg->transforms and cfg->transport_ranges as used in pdu_decl
       (mate_grammar.lemon).
    
    Tested on a http capture with: tshark -o mate.config:tcp.mate -r ...
    where tcp.mate is from
    https://wiki.wireshark.org/Mate/GettingStarted?action=AttachFile&do=get&target=tcp.mate
    
    Change-Id: I4c06f948136fc30dfcdb56f7ac8a32a2326ae30d
    Reviewed-on: https://code.wireshark.org/review/9221
    Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
    

Actions performed:

    from  305d983   capchild: fix uninitialized data pointer on failure
    adds  a36db75   plugins/mate: fix some memleaks


Summary of changes:
 plugins/mate/mate_parser.l  |   17 ++++++++++-------
 plugins/mate/mate_runtime.c |    3 ++-
 plugins/mate/mate_util.c    |    1 +
 3 files changed, 13 insertions(+), 8 deletions(-)