]> Cypherpunks.ru repositories - gostls13.git/commit
std: fix various nilness findings
authorAlan Donovan <adonovan@google.com>
Wed, 19 Apr 2023 22:48:00 +0000 (18:48 -0400)
committerGopher Robot <gobot@golang.org>
Thu, 20 Apr 2023 01:07:29 +0000 (01:07 +0000)
commit9d35ebba062cae9cc7bd716ad279ac7d44060a93
tree65616ae5f51f4c556dfacb2ae1f34bb00baf6844
parent5c865c78c378548c282b22d96e6d0375079d4417
std: fix various nilness findings

Found by running
$ go run golang.org/x/tools/go/analysis/passes/nilness/cmd/nilness@latest std

No actual bugs--other than one panic(nil)--but a
few places where error nilness was unclear.

Change-Id: Ia916ba30f46f29c1bcf928cc62280169b922463a
Reviewed-on: https://go-review.googlesource.com/c/go/+/486675
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: Alan Donovan <adonovan@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Alan Donovan <adonovan@google.com>
src/bytes/buffer_test.go
src/crypto/internal/bigmod/nat_test.go
src/encoding/xml/xml_test.go
src/net/timeout_test.go
src/os/timeout_test.go
src/testing/example.go