From 23d3e3d665ce2826477bf04ceabe961330cfcd5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Mayer?= Date: Fri, 13 Sep 2013 10:13:19 +0000 Subject: Dario Lombardo via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9147 Migration from emem to wmem for trivial cases (ep_alloc only). svn path=/trunk/; revision=52002 --- epan/dissectors/packet-cdp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'epan/dissectors/packet-cdp.c') diff --git a/epan/dissectors/packet-cdp.c b/epan/dissectors/packet-cdp.c index 23fc1ade61..c6329932f1 100644 --- a/epan/dissectors/packet-cdp.c +++ b/epan/dissectors/packet-cdp.c @@ -31,6 +31,7 @@ #include #include #include +#include #include #include @@ -245,7 +246,7 @@ dissect_cdp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) if (data_length & 1) { guint8 *padded_buffer; /* Allocate new buffer */ - padded_buffer = (guint8 *)ep_alloc(data_length+1); + padded_buffer = (guint8 *)wmem_alloc(wmem_packet_scope(), data_length+1); tvb_memcpy(tvb, padded_buffer, 0, data_length); /* Swap bytes in last word */ padded_buffer[data_length] = padded_buffer[data_length-1]; -- cgit v1.2.3