Skip to content

Commit

Permalink
Merge pull request #6 from wcsmith/receive-timestamps-gap
Browse files Browse the repository at this point in the history
Make ACK_RECEIVE_TIMESTAMPS frame Gap more efficient and QUIC-like.
  • Loading branch information
ianswett authored Oct 24, 2021
2 parents 063d88c + 1050cd1 commit 502e586
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions quic/core/quic_framer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4188,10 +4188,11 @@ bool QuicFramer::ProcessIetfTimestampsInAckFrame(QuicPacketNumber largest_acked,
return false;
}
}
visitor_->OnAckTimestamp(packet_number - j,
visitor_->OnAckTimestamp(packet_number,
creation_time_ + last_timestamp_);
packet_number--;
}
packet_number = packet_number - (timestamp_count - 1);
packet_number--;
}
return true;
}
Expand Down
4 changes: 2 additions & 2 deletions quic/core/quic_framer_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4113,15 +4113,15 @@ TEST_P(QuicFramerTest, AckFrameMultipleReceiveTimestampRanges) {

// Timestamp range 2 (one packet).
{ "Unable to read receive timestamp gap.",
{ kVarInt62OneByte + 0x07 }},
{ kVarInt62OneByte + 0x05 }},
{ "Unable to read receive timestamp count.",
{ kVarInt62OneByte + 0x01 }},
{ "Unable to read receive timestamp delta.",
{ kVarInt62TwoBytes + 0x10, 0x00 }},

// Timestamp range 3 (two packets).
{ "Unable to read receive timestamp gap.",
{ kVarInt62OneByte + 0x0a }},
{ kVarInt62OneByte + 0x08 }},
{ "Unable to read receive timestamp count.",
{ kVarInt62OneByte + 0x02 }},
{ "Unable to read receive timestamp delta.",
Expand Down

0 comments on commit 502e586

Please sign in to comment.