提交 0bfdb9cb 编写于 作者: M Michal Privoznik

wireshark: s/ep_alloc/wmem_alloc/

In wireshark, they have introduced their own memory allocator
wmem. This means that we need to adapt our code to that change
too. Notably 0ad15f88ccf434e8210ca is the wireshark commit you
want to look at. It's the one where they dropped the old API. The
new allocator has been introduced in 84cc3daa (v1.10.0), however,
was not exposed until 5c05c9e0 (v1.10.0). Since we already are
requiring 1.11.3 or higher no other change is needed.
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
上级 d3ede96d
...@@ -113,7 +113,7 @@ format_xdr_bytes(guint8 *bytes, guint32 length) ...@@ -113,7 +113,7 @@ format_xdr_bytes(guint8 *bytes, guint32 length)
if (length == 0) if (length == 0)
return ""; return "";
buf = ep_alloc(length*2 + 1); buf = wmem_alloc(wmem_packet_scope(), length*2 + 1);
for (i = 0; i < length; i++) { for (i = 0; i < length; i++) {
/* We know that buf has enough size to contain /* We know that buf has enough size to contain
2 * length + '\0' characters. */ 2 * length + '\0' characters. */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册