You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the user created an httptest.Server directly without using a
constructor it won't have the new unexported 'client' field. So don't
assume it's non-nil.
Fixesgolang#19729
Change-Id: Ie92e5da66cf4e7fb8d95f3ad0f4e3987d3ae8b77
Reviewed-on: https://go-review.googlesource.com/38710
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Kevin Burke <kev@inburke.com>
What version of Go are you using (
go version
)?go master branch as of today
go version devel +ecc6a81 Sat Mar 25 00:35:35 2017 +0000 linux/amd64
What operating system and processor architecture are you using (
go env
)?What did you do?
etcd(https://github.com/coreos/etcd/blob/master/integration/cluster.go#L717-L720) calls
where
hs
is*httptest.Server
What did you expect to see?
It should not panic from
nil pointer dereference
in the followinghttptest.Server.Close
What did you see instead?
I confirm that after
CloseClientConnections
,s.client
inClose
isnil
--so panic-ed.It was added from fbf4dd9#diff-4d34e6d5bd560e4ac6fd23ee5d9bda5fR209
Or are we doing anything wrong here?
Thanks a lot in advance!
The text was updated successfully, but these errors were encountered: