diff options
author | Guy Harris <guy@alum.mit.edu> | 2003-08-07 18:28:33 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2003-08-07 18:28:33 +0000 |
commit | 3a9d1edd45e9e74b28b29bd95a12e9685f640462 (patch) | |
tree | 1caa2e835ed9ecb407c2e09f9e4d69f7071b4e57 /packet-wtp.c | |
parent | 9a555293e995b792a207b7dd02df11b48fc611eb (diff) |
From Lo�c Minier: allow packets with no payload to participate in
reassembly, as the last packet of a fragmented WTP message can have a
payload length of 0.
svn path=/trunk/; revision=8147
Diffstat (limited to 'packet-wtp.c')
-rw-r--r-- | packet-wtp.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/packet-wtp.c b/packet-wtp.c index 301f3ab92c..d449441703 100644 --- a/packet-wtp.c +++ b/packet-wtp.c @@ -2,7 +2,7 @@ * * Routines to dissect WTP component of WAP traffic. * - * $Id: packet-wtp.c,v 1.51 2003/07/29 22:10:18 guy Exp $ + * $Id: packet-wtp.c,v 1.52 2003/08/07 18:28:33 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -595,9 +595,13 @@ dissect_wtp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) } /* * Any remaining data ought to be WSP data (if not WTP ACK, NACK - * or ABORT pdu), so hand off (defragmented) to the WSP dissector + * or ABORT pdu), so hand off (defragmented) to the WSP dissector. + * Note that the last packet of a fragmented WTP message needn't + * contain any data, so we allow payloadless packets to be + * reassembled. (XXX - does the reassembly code handle this + * for packets other than the last packet?) */ - if ((tvb_reported_length_remaining(tvb, offCur + cbHeader + vHeader) > 0) && + if ((tvb_reported_length_remaining(tvb, offCur + cbHeader + vHeader) >= 0) && ! ((pdut==ACK) || (pdut==NEGATIVE_ACK) || (pdut==ABORT))) { int dataOffset = offCur + cbHeader + vHeader; |