aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Reusch <creusch@crnetpackets.com>2021-06-03 22:45:34 +0200
committerPascal Quantin <pascal@wireshark.org>2021-06-05 10:17:05 +0000
commit9eb1c665c661bf43bcded79289fc9f154ae45f63 (patch)
tree6d4664b20284eecb0ceea444efbbb3d0f6f87a9b
parent57776c7641729aad4b2a693027f599a5f6b27ca1 (diff)
tcp: Fix dissection of DSACK
DSACK blocks (the first SACK block in a TCP SACK option, with right edge being lower or equal to the ACK filed) are now identified correctly. Closes #17315 (cherry picked from commit 7179e1d1fbd7e6fb3d4f8848e432dd7c5ad54dae)
-rw-r--r--epan/dissectors/packet-tcp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/epan/dissectors/packet-tcp.c b/epan/dissectors/packet-tcp.c
index 63e3657ae4..759d2a1dfd 100644
--- a/epan/dissectors/packet-tcp.c
+++ b/epan/dissectors/packet-tcp.c
@@ -4250,7 +4250,7 @@ dissect_tcpopt_sack(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* d
* (1) A D-SACK block is only used to report a duplicate contiguous sequence of data received by
* the receiver in the most recent packet.
*/
- if (GE_SEQ(tcph->sack_right_edge[0], tcph->th_ack) ||
+ if (LE_SEQ(tcph->sack_right_edge[0], tcph->th_ack) ||
(tcph->num_sack_ranges > 1 &&
LT_SEQ(tcph->sack_left_edge[1], tcph->sack_right_edge[0]) &&
GE_SEQ(tcph->sack_right_edge[1], tcph->sack_right_edge[0]))