aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Morriss <jeff.morriss@ulticom.com>2007-11-16 19:32:59 +0000
committerJeff Morriss <jeff.morriss@ulticom.com>2007-11-16 19:32:59 +0000
commit03b581e9215c604261cdb7d604fced8e376e996b (patch)
tree240a47153bbbc38d87b1deb2d961caaf89f94c63
parentd24d657f75f9f068f022503566ac602540ed2318 (diff)
When reassembly is turned off don't pass non-first fragments to subdissectors: they will have no idea what they're getting and will exception out anyway.
svn path=/trunk/; revision=23469
-rw-r--r--epan/dissectors/packet-sctp.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/epan/dissectors/packet-sctp.c b/epan/dissectors/packet-sctp.c
index e7c965cb1f..e57002e95d 100644
--- a/epan/dissectors/packet-sctp.c
+++ b/epan/dissectors/packet-sctp.c
@@ -2733,8 +2733,18 @@ dissect_data_chunk(tvbuff_t *chunk_tvb,
/* Yes. */
pinfo->fragmented = TRUE;
- /* if reassembly off just mark as fragment for next dissector and proceed */
- if (!use_reassembly) return dissect_payload(payload_tvb, pinfo, tree, payload_proto_id);
+ /* if reassembly is off just mark as fragment for next dissector and proceed */
+ if (!use_reassembly)
+ {
+ /* Don't pass on non-first fragments since the next dissector will
+ * almost certainly not understand the data.
+ */
+ if (b_bit)
+ return dissect_payload(payload_tvb, pinfo, tree, payload_proto_id);
+
+ /* else */
+ return FALSE;
+ }
/* if unordered set stream_seq_num to 0 for easier handling */
if (u_bit) stream_seq_num = 0;