rfc7468: Fix a memory leak
Read the base64 decoded data into a wmem_alloc memory to avoid a memory leak for each opened file. Change-Id: I4cbb2c15dea43183ed741d54ae7c6ea2e83e46c0 Reviewed-on: https://code.wireshark.org/review/31112 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
parent
9132725ab0
commit
d749beafb9
|
@ -296,7 +296,7 @@ dissect_rfc7468(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
|
|||
* First, grow the buffer as needed.
|
||||
*/
|
||||
databufsize += (linelen / 4) * 3 + 3;
|
||||
databuf = (guint8 *)g_realloc(databuf, databufsize);
|
||||
databuf = (guint8 *)wmem_realloc(pinfo->pool, databuf, databufsize);
|
||||
|
||||
/*
|
||||
* Now decode into it.
|
||||
|
|
Loading…
Reference in New Issue