QUIC: fixed off-by-one in frame range handler.

The ctx->pnum is incremented after the packet is sent, thus pointing to the
next packet number, which should not be used in comparison.
This commit is contained in:
Vladimir Homutov 2020-06-18 11:16:35 +03:00
parent 3b3264dc25
commit a213258b5b

View File

@ -2262,7 +2262,7 @@ ngx_quic_handle_ack_frame_range(ngx_connection_t *c, ngx_quic_send_ctx_t *ctx,
if (!found) {
if (max <= ctx->pnum) {
if (max < ctx->pnum) {
/* duplicate ACK or ACK for non-ack-eliciting frame */
return NGX_OK;
}