Use ngtcp2_conn_handle_expiry
This commit is contained in:
parent
a77031df80
commit
3c676d0836
|
@ -485,16 +485,11 @@ int Client::quic_pkt_timeout() {
|
||||||
int rv;
|
int rv;
|
||||||
auto now = timestamp(worker->loop);
|
auto now = timestamp(worker->loop);
|
||||||
|
|
||||||
if (ngtcp2_conn_loss_detection_expiry(quic.conn) <= now) {
|
rv = ngtcp2_conn_handle_expiry(quic.conn, now);
|
||||||
rv = ngtcp2_conn_on_loss_detection_timer(quic.conn, now);
|
|
||||||
if (rv != 0) {
|
if (rv != 0) {
|
||||||
quic.last_error = quic::err_transport(NGTCP2_ERR_INTERNAL);
|
quic.last_error = quic::err_transport(NGTCP2_ERR_INTERNAL);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (ngtcp2_conn_ack_delay_expiry(quic.conn) <= now) {
|
|
||||||
ngtcp2_conn_cancel_expired_ack_delay_timer(quic.conn, now);
|
|
||||||
}
|
|
||||||
|
|
||||||
return write_quic();
|
return write_quic();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue