aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Cistera <michael.cistera@netscout.com>2016-03-23 09:34:24 -0600
committerJeff Morriss <jeff.morriss.ws@gmail.com>2016-03-24 00:04:03 +0000
commitdf8b5cbdc0d012c750a5ae08885a57e0de13ebc5 (patch)
treef50e5c17451fb9a2382383e6252b366ae4147bc8
parent5a166757ecb832a79489163d325c72a520b63163 (diff)
Detect spurious retransmissions when the full segment is retransmitted
The TCP dissector failed to recognize spurious retransmissions when the last ack exactly equaled the retransmitted packet's sequence number plus the len. This is standard TCP behavior so this feature was broken in most cases. Bug: 12282 Change-Id: I90196cc79e786f92fd0d7be32816aad1d69d5718 Reviewed-on: https://code.wireshark.org/review/14592 Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
-rw-r--r--epan/dissectors/packet-tcp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-tcp.c b/epan/dissectors/packet-tcp.c
index 3e79addce6..c0159a1eaa 100644
--- a/epan/dissectors/packet-tcp.c
+++ b/epan/dissectors/packet-tcp.c
@@ -1586,10 +1586,10 @@ finished_fwd:
}
/* Check for spurious retransmission. If the current seq + segment length
- * is less then the receivers lastack, the packet contains duplicated
- * data and may be considered spurious.
+ * is less than or equal to the receiver's lastack, the packet contains
+ * duplicate data and may be considered spurious.
*/
- if ( seq + seglen < tcpd->rev->lastack ) {
+ if ( seq + seglen <= tcpd->rev->lastack ) {
if(!tcpd->ta){
tcp_analyze_get_acked_struct(pinfo->num, seq, ack, TRUE, tcpd);
}