From: Emmanuel T Odeke Date: Fri, 7 May 2021 05:15:11 +0000 (-0700) Subject: doc/go1.17: document encoding/binary.Uvarint max read of 10 bytes X-Git-Tag: go1.17beta1~206 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=af6123a865;p=gostls13.git doc/go1.17: document encoding/binary.Uvarint max read of 10 bytes Updates #41185 For #44513. Fixes #46009 Change-Id: I60f4d891b897809765acc0aace037c78e95bb4f7 Reviewed-on: https://go-review.googlesource.com/c/go/+/317929 Trust: Emmanuel Odeke Reviewed-by: Keith Randall --- diff --git a/doc/go1.17.html b/doc/go1.17.html index a2e0f9454b..3cd324e0ab 100644 --- a/doc/go1.17.html +++ b/doc/go1.17.html @@ -303,7 +303,10 @@ Do not send CLs removing the interior tags from such phrases.
encoding/binary

- TODO: https://golang.org/cl/299531: limit bytes read by Uvarint to <= 10 + binary.Uvarint will stop reading after 10 bytes to avoid + wasted computations. If more than 10 bytes are needed, the byte count returned is -11. +
+ Previous Go versions could return larger negative counts when reading incorrectly encoded varints.