aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-irc.c
diff options
context:
space:
mode:
authorMartin Kaiser <wireshark@kaiser.cx>2014-01-22 22:28:27 +0000
committerMartin Kaiser <wireshark@kaiser.cx>2014-01-22 22:28:27 +0000
commit0f44a72088ac8975531bd4460fd912486315c2b0 (patch)
treec0fe9963c0e057e6f46234398a77cc9062347f9f /epan/dissectors/packet-irc.c
parent0c44ca68255da381b0916610a9fb9ebf9ec6c4ce (diff)
use tvb_get_string_enc(), the strings are 7-bit ascii
svn path=/trunk/; revision=54914
Diffstat (limited to 'epan/dissectors/packet-irc.c')
-rw-r--r--epan/dissectors/packet-irc.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/epan/dissectors/packet-irc.c b/epan/dissectors/packet-irc.c
index 54ce100e6a..28cdc6ee9a 100644
--- a/epan/dissectors/packet-irc.c
+++ b/epan/dissectors/packet-irc.c
@@ -169,7 +169,8 @@ dissect_irc_request(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, int off
if (eoc_offset == -1)
{
proto_tree_add_item(request_tree, hf_irc_request_command, tvb, offset, end_offset-offset, ENC_ASCII|ENC_NA);
- col_append_fstr( pinfo->cinfo, COL_INFO, " (%s)", tvb_get_string(wmem_packet_scope(), tvb, offset, end_offset-offset));
+ col_append_fstr( pinfo->cinfo, COL_INFO, " (%s)",
+ tvb_get_string_enc(wmem_packet_scope(), tvb, offset, end_offset-offset, ENC_ASCII|ENC_NA));
/* Warn if there is a "numeric" command */
if ((end_offset-offset == 3) &&
@@ -183,7 +184,7 @@ dissect_irc_request(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, int off
}
proto_tree_add_item(request_tree, hf_irc_request_command, tvb, offset, eoc_offset-offset, ENC_ASCII|ENC_NA);
- str_command = tvb_get_string(wmem_packet_scope(), tvb, offset, eoc_offset-offset);
+ str_command = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, eoc_offset-offset, ENC_ASCII|ENC_NA);
col_append_fstr( pinfo->cinfo, COL_INFO, " (%s)", str_command);
/* Warn if there is a "numeric" command */
@@ -337,7 +338,8 @@ dissect_irc_response(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, int of
if (eoc_offset == -1)
{
proto_tree_add_item(response_tree, hf_irc_response_command, tvb, offset, end_offset-offset, ENC_ASCII|ENC_NA);
- col_append_fstr( pinfo->cinfo, COL_INFO, " (%s)", tvb_get_string(wmem_packet_scope(), tvb, offset, end_offset-offset));
+ col_append_fstr( pinfo->cinfo, COL_INFO, " (%s)",
+ tvb_get_string_enc(wmem_packet_scope(), tvb, offset, end_offset-offset, ENC_ASCII|ENC_NA));
/* if response command is numeric, allow it to be filtered as an integer */
if ((end_offset-offset == 3) &&
@@ -353,7 +355,7 @@ dissect_irc_response(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, int of
}
proto_tree_add_item(response_tree, hf_irc_response_command, tvb, offset, eoc_offset-offset, ENC_ASCII|ENC_NA);
- str_command = tvb_get_string(wmem_packet_scope(), tvb, offset, eoc_offset-offset);
+ str_command = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, eoc_offset-offset, ENC_ASCII|ENC_NA);
col_append_fstr( pinfo->cinfo, COL_INFO, " (%s)", str_command);
/* if response command is numeric, allow it to be filtered as an integer */