Commit 214bf680 authored by Brad Fitzpatrick's avatar Brad Fitzpatrick

net/http: remove TODO about the Server's base context

I decided not to expand the API for this per discusion on #16220.

Fixes #16220

Change-Id: I65cb2eacd4ec28c79438a8f7c30024524a484ce6
Reviewed-on: https://go-review.googlesource.com/30082Reviewed-by: 's avatarDaniel Theophanes <kardianos@gmail.com>
Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
parent dd748cf3
......@@ -2264,9 +2264,7 @@ func (srv *Server) Serve(l net.Listener) error {
return err
}
// TODO: allow changing base context? can't imagine concrete
// use cases yet.
baseCtx := context.Background()
baseCtx := context.Background() // base is always background, per Issue 16220
ctx := context.WithValue(baseCtx, ServerContextKey, srv)
ctx = context.WithValue(ctx, LocalAddrContextKey, l.Addr())
for {
......
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