]> Cypherpunks repositories - gostls13.git/commit
encoding/binary: fix bound check
authorAlexandru Moșoi <mosoi@google.com>
Mon, 21 Mar 2016 14:05:54 +0000 (15:05 +0100)
committerAlexandru Moșoi <alexandru@mosoi.ro>
Mon, 21 Mar 2016 19:22:22 +0000 (19:22 +0000)
commit478b594d5117729694deecbcb205bb15b6085f7a
tree334b4985c5311ae01bf94e635573c8699dd28d0d
parent6a33f7765f79cf2f00f5ca55832d2cfab8beb289
encoding/binary: fix bound check

The inserted early bound checks cause the slice
to expand beyond the original length of the slice.

Change-Id: Ib38891605f4a9a12d3b9e2071a5f77640b083d2d
Reviewed-on: https://go-review.googlesource.com/20981
Reviewed-by: Keith Randall <khr@golang.org>
Reviewed-by: Minux Ma <minux@golang.org>
src/encoding/binary/binary.go
src/encoding/binary/binary_test.go