diff options
author | Martin Kaiser <wireshark@kaiser.cx> | 2014-03-26 12:14:59 +0100 |
---|---|---|
committer | Martin Kaiser <wireshark@kaiser.cx> | 2014-03-26 22:16:03 +0000 |
commit | 436100c66a496fe7bc7a9dd0ac41c244bc7dc52d (patch) | |
tree | 48c317a15b9fc069b09a67fcd3d79dcc30b60f3a /epan/dissectors/file-png.c | |
parent | 482a3cd1f1c533f470c6cc2c9a63ddb7bf56e3b3 (diff) |
use the correct png chunk len
the parameter for proto_tree_add_text() is the length, not the end offset
Change-Id: Ie24d5982b7ff13363061fb087438dd714cae748a
Reviewed-on: https://code.wireshark.org/review/837
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Diffstat (limited to 'epan/dissectors/file-png.c')
-rw-r--r-- | epan/dissectors/file-png.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/epan/dissectors/file-png.c b/epan/dissectors/file-png.c index b47a6c8478..9438b844e2 100644 --- a/epan/dissectors/file-png.c +++ b/epan/dissectors/file-png.c @@ -343,7 +343,7 @@ dissect_png(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void *da str[3]=tvb_get_guint8(tvb, offset+7); str[4]=0; - it=proto_tree_add_text(tree, tvb, offset, offset+8+len+4, "%s", str); + it=proto_tree_add_text(tree, tvb, offset, 4+4+len+4, "%s", str); chunk_tree=proto_item_add_subtree(it, ett_png_chunk); proto_tree_add_item(chunk_tree, &hfi_png_chunk_len, tvb, offset, 4, ENC_BIG_ENDIAN); |