Commit 090ebbdf authored by Brad Fitzpatrick's avatar Brad Fitzpatrick

http2: fix Go 1.6 build

We still support Go 1.6 for a few more days. (it'd normally be dropped
after Go 1.9 final is out)

And maybe we'll need to make a special case for supporting it longer
than normal if gRPC needs to.

Change-Id: I78675f1ef26aa09436a70d0f8aa3a0958768dd14
Reviewed-on: https://go-review.googlesource.com/53641Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
parent 945ddfdd
......@@ -354,8 +354,8 @@ func (t *Transport) RoundTripOpt(req *http.Request, opt RoundTripOpt) (*http.Res
select {
case <-time.After(time.Second * time.Duration(backoff)):
continue
case <-req.Context().Done():
return nil, req.Context().Err()
case <-reqContext(req).Done():
return nil, reqContext(req).Err()
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment