blob: 2e0caaf1c9b5449dc5b7fed4631fd1c444dd796e [file] [log] [blame]
MathiasRaoulffdc72d2020-02-07 16:29:05 +00001diff --git a/lib/quicly.c b/lib/quicly.c
2index 71fa149..668677f 100644
3--- a/lib/quicly.c
4+++ b/lib/quicly.c
5@@ -3631,10 +3631,14 @@ int quicly_send(quicly_conn_t *conn, quicly_datagram_t **packets, size_t *num_pa
6 * progress (i.e. due to the payload of lost packet being cancelled), then PTO for the previously sent packet. To accomodate
7 * that, we allow to rerun the do_send function just once.
8 */
9- if (s.num_packets == 0 && conn->egress.loss.alarm_at <= now) {
10+ if (conn->egress.loss.alarm_at <= now) {
11 assert(conn->egress.loss.alarm_at == now);
12- if ((ret = do_send(conn, &s)) != 0)
13- return ret;
14+ if (s.num_packets == 0) {
15+ if ((ret = do_send(conn, &s)) != 0)
16+ return ret;
17+ } else {
18+ conn->egress.loss.alarm_at = now + 1;
19+ }
20 }
21 assert_consistency(conn, 1);