Wireshark-commits: [Wireshark-commits] master 56a9b53: zbee-nwk-gp: fix a memory leak when keys are

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Tue, 11 Aug 2015 04:09:50 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=56a9b5377312f0bb769ecb710f83430f641f41dd
Submitter: Anders Broman (a.broman58@xxxxxxxxx)
Changed: branch: master
Repository: wireshark

Commits:

56a9b53 by Martin Kaiser (wireshark@xxxxxxxxx):

    zbee-nwk-gp: fix a memory leak when keys are defined in the preferences
    
    ==5932== 33 (32 direct, 1 indirect) bytes in 1 blocks are definitely lost in loss record 2,124 of 4,121
    ==5932==    at 0x4C28BED: malloc (vg_replace_malloc.c:263)
    ==5932==    by 0xA024F30: g_malloc (gmem.c:159)
    ==5932==    by 0xA03A9E5: g_memdup (gstrfuncs.c:384)
    ==5932==    by 0x70754D2: gp_init_zbee_security (packet-zbee-nwk-gp.c:1459)
    ==5932==    by 0xA03A78C: g_slist_foreach (gslist.c:840)
    ==5932==    by 0x67E867C: init_dissection (packet.c:249)
    ==5932==    by 0x67DC202: epan_new (epan.c:160)
    ==5932==    by 0x414B16: cf_open (tshark.c:2464)
    ==5932==    by 0x40CF8A: main (tshark.c:2169)
    
    Change-Id: I7c0ce0717957525ca18eb4888ed3389debc89a49
    Reviewed-on: https://code.wireshark.org/review/9967
    Petri-Dish: Martin Kaiser <wireshark@xxxxxxxxx>
    Tested-by: Petri Dish Buildbot <buildbot-no-reply@xxxxxxxxxxxxx>
    Reviewed-by: Anders Broman <a.broman58@xxxxxxxxx>
    

Actions performed:

    from  b1be6bc   zigbee: remove some more if (tree) checks
    adds  56a9b53   zbee-nwk-gp: fix a memory leak when keys are defined in the preferences


Summary of changes:
 epan/dissectors/packet-zbee-nwk-gp.c |   23 +++++++++++++++++++----
 1 file changed, 19 insertions(+), 4 deletions(-)