From 677ad13afcc1c21b98fdaf6933b5c62451337f94 Mon Sep 17 00:00:00 2001 From: Tom Thorogood Date: Fri, 13 Sep 2019 20:23:22 +0930 Subject: [PATCH] pc.alt == nil not w.pc.alt == nil --- src/net/http/transport.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/net/http/transport.go b/src/net/http/transport.go index 7be9fe05cbe..209414d85b1 100644 --- a/src/net/http/transport.go +++ b/src/net/http/transport.go @@ -1197,7 +1197,7 @@ func (t *Transport) getConn(treq *transportRequest, cm connectMethod) (pc *persi pc := w.pc // Trace only for HTTP/1. // HTTP/2 calls trace.GotConn itself. - if w.pc.alt == nil && trace != nil && trace.GotConn != nil { + if pc.alt == nil && trace != nil && trace.GotConn != nil { trace.GotConn(pc.gotIdleConnTrace(pc.idleAt)) } // set request canceler to some non-nil function so we