diff options
author | Evan Huus <eapache@gmail.com> | 2014-03-02 09:58:49 -0500 |
---|---|---|
committer | Evan Huus <eapache@gmail.com> | 2014-03-02 22:31:22 +0000 |
commit | a79fbf039768a3da0402d492c77b64c7f76c2345 (patch) | |
tree | 2c33a61e9d43b1641994af5e860def4440d9cd76 /epan | |
parent | 9afdd44eec055a06291f3ccd9d12ebd2fcf4a809 (diff) |
Don't pass an invalid length to proto_item_set_len
Fixes bug #9818.
Change-Id: I4fb4cf2b5b31ed6efc55a48df67f2ec4949d47c3
Reviewed-on: https://code.wireshark.org/review/442
Reviewed-by: Evan Huus <eapache@gmail.com>
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dissectors/packet-giop.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/epan/dissectors/packet-giop.c b/epan/dissectors/packet-giop.c index 544b20a69d..5bdc4ab14e 100644 --- a/epan/dissectors/packet-giop.c +++ b/epan/dissectors/packet-giop.c @@ -3926,7 +3926,8 @@ static void decode_ServiceContextList(tvbuff_t *tvb, packet_info *pinfo, proto_t stream_is_be, boundary, &encapsulation_is_be , &encapsulation_boundary); - proto_item_set_len(tf_st1, 8 + context_data_len); + if ((int)(8 + context_data_len) >= 8) + proto_item_set_len(tf_st1, 8 + context_data_len); sub_tree1 = proto_item_add_subtree (tf_st1, ett_giop_scl_st1); if (context_data_len == 0) |