ipn/ipnserver: document potential race, start on test for it

This commit is contained in:
Brad Fitzpatrick
2020-03-03 09:15:11 -08:00
parent ef1f967ec0
commit 06092a3af3
2 changed files with 78 additions and 1 deletions

View File

@ -116,7 +116,7 @@ func Run(rctx context.Context, logf logger.Logf, logid string, opts Options, e w
var s net.Conn
serverToClient := func(b []byte) {
if s != nil {
if s != nil { // TODO: racy access to s?
ipn.WriteMsg(s, b)
}
}