Subject: [quicwg/base-drafts] lost_pn can go negative (#2611)

From: Lars Eggert <[email-masked]>
Date: Fri, 12 Apr 2019 09:14:58 +0000 (UTC)

in `DetectLostPackets`, `lost_pn` is computed as
```
lost_pn = largest_acked_packet[pn_space] - kPacketThreshold
```
However, `largest_acked_packet` is initialied to zero
```
largest_acked_packet[pn_space] = 0
```
and so the subtraction can cause `lost_pn` to go negative when `DetectLostPackets` is called before an ACK is received (since it will be updated only in `OnAckReceived`.

Suggest to initialize `largest_acked_packet` to infinity and to explicitly check for this case.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611

---

From: Marten Seemann <[email-masked]>
Date: Fri, 12 Apr 2019 02:36:57 -0700

I support this proposal, since the way we’re initializing largest_acked_packet is wrong: we’re initializing it to 0, although we decided that 0 is a valid packet number.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611#issuecomment-482508794

---

From: ianswett <[email-masked]>
Date: Fri, 19 Apr 2019 19:47:40 +0000 (UTC)

Closed #2611.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611#event-2288895612

---

From: ianswett <[email-masked]>
Date: Fri, 19 Apr 2019 12:47:40 -0700

Closed by #2621 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611#issuecomment-484997322

---

From: ianswett <[email-masked]>
Date: Wed, 24 Apr 2019 14:57:55 +0000 (UTC)

I merged #2611 into a random local branch instead of head, so I'm reopening this.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611#issuecomment-486278100

---

From: ianswett <[email-masked]>
Date: Wed, 24 Apr 2019 07:57:54 -0700

Reopened #2611.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611#event-2297492603

---

From: ianswett <[email-masked]>
Date: Mon, 29 Apr 2019 13:18:39 -0700

Closed #2611 via #2651.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/quicwg/base-drafts/issues/2611#event-2307795631