aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-slsk.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2017-01-29 21:53:49 -0500
committerMichael Mann <mmann78@netscape.net>2017-01-31 02:26:35 +0000
commitd802b5b0ec8e10fbf64f6c76815b759323029bb4 (patch)
tree2071ff718141347ff02c8dc02aafb9090e8fc5e1 /epan/dissectors/packet-slsk.c
parent60a877167f05644a5a75676798084027accd1c3d (diff)
Add format_text_wmem.
This allows for a wmem_allocator for users of format_text who want it (dissectors for wmem_packet_scope()). This lessens the role of current format_text functionality in hopes that it will eventually be replaced. Change-Id: I970557a65e32aa79634a3fcc654ab641b871178e Reviewed-on: https://code.wireshark.org/review/19855 Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-slsk.c')
-rw-r--r--epan/dissectors/packet-slsk.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-slsk.c b/epan/dissectors/packet-slsk.c
index e0aa8acf53..6b095adc9b 100644
--- a/epan/dissectors/packet-slsk.c
+++ b/epan/dissectors/packet-slsk.c
@@ -968,7 +968,7 @@ static int dissect_slsk_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
str = tvb_get_string_enc(wmem_packet_scope(), tvb, offset+4, len, ENC_ASCII);
proto_tree_add_string_format_value(slsk_tree, hf_slsk_connection_type, tvb, offset+4, len, str,
"%s (Char: %s)", connection_type(str),
- format_text(str, len));
+ format_text_wmem(wmem_packet_scope(), str, len));
offset += 4+len;
}
else if (check_slsk_format(tvb, offset, "issiii")) {
@@ -988,7 +988,7 @@ static int dissect_slsk_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
str = tvb_get_string_enc(wmem_packet_scope(), tvb, offset+4, len, ENC_ASCII);
proto_tree_add_string_format_value(slsk_tree, hf_slsk_connection_type, tvb, offset+4, len, str,
"%s (Char: %s)", connection_type(str),
- format_text(str, len));
+ format_text_wmem(wmem_packet_scope(), str, len));
offset += 4+len;
proto_tree_add_item(slsk_tree, hf_slsk_ip, tvb, offset, 4, ENC_BIG_ENDIAN);
offset += 4;
@@ -2338,7 +2338,7 @@ static int dissect_slsk_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
str = tvb_get_string_enc(wmem_packet_scope(), tvb, offset+4, len, ENC_ASCII);
proto_tree_add_string_format_value(slsk_tree, hf_slsk_connection_type, tvb, offset+4, len, str,
"%s (Char: %s)", connection_type(str),
- format_text(str, len));
+ format_text_wmem(wmem_packet_scope(), str, len));
offset += 4+len;
proto_tree_add_uint(slsk_tree, hf_slsk_token, tvb, offset, 4, tvb_get_letohl(tvb, offset));
offset += 4;