aboutsummaryrefslogtreecommitdiffstats
path: root/epan/tvbuff_zlib.c
diff options
context:
space:
mode:
authorPascal Quantin <pascal.quantin@gmail.com>2016-04-21 19:12:26 +0200
committerAnders Broman <a.broman58@gmail.com>2016-04-22 04:32:32 +0000
commit9abbf8b69d830bff29705991d6ebb760ec2f4454 (patch)
tree7a75eda3bf85ae8846511215c4c0ef0a42ca1940 /epan/tvbuff_zlib.c
parent9de18e88f501ef953395b8cadf9dbc9b79ce40cc (diff)
Do not mix wmem and glib allocators
Change-Id: I0e845668a1b9dbec93ea920a8585ecfe60f001d1 Reviewed-on: https://code.wireshark.org/review/15044 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/tvbuff_zlib.c')
-rw-r--r--epan/tvbuff_zlib.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/epan/tvbuff_zlib.c b/epan/tvbuff_zlib.c
index 045b45faa8..3f23f57d58 100644
--- a/epan/tvbuff_zlib.c
+++ b/epan/tvbuff_zlib.c
@@ -68,7 +68,8 @@ tvb_uncompress(tvbuff_t *tvb, const int offset, int comprlen)
return NULL;
}
- compr = (guint8 *)tvb_memdup(NULL, tvb, offset, comprlen);
+ compr = (guint8 *)g_malloc(comprlen);
+ tvb_memcpy(tvb, compr, offset, comprlen);
if (!compr)
return NULL;