oops -- remove some unused code

This commit is contained in:
Josh Humphries 2017-12-13 15:46:56 -05:00
parent 91fb94b700
commit 1eec3bcbd6
1 changed files with 0 additions and 4 deletions

View File

@ -854,9 +854,6 @@ func BlockingDial(ctx context.Context, address string, creds credentials.Transpo
// grpc.Dial doesn't provide any information on permanent connection errors (like
// TLS handshake failures). So in order to provide good error messages, we need a
// custom dialer that can provide that info. That means we manage the TLS handshake.
var wg sync.WaitGroup
wg.Add(1)
var once sync.Once
result := make(chan interface{}, 1)
writeResult := func(res interface{}) {
@ -868,7 +865,6 @@ func BlockingDial(ctx context.Context, address string, creds credentials.Transpo
}
dialer := func(address string, timeout time.Duration) (net.Conn, error) {
once.Do(func() { wg.Done() })
ctx, cancel := context.WithTimeout(ctx, timeout)
defer cancel()
conn, err := (&net.Dialer{Cancel: ctx.Done()}).Dial("tcp", address)