Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
internal/lsp/debug: splice in updated servers rather than overwrite
Updating server info was racing with rendering debug templates, because the state mutex only guards the servers slice, not the values contained in that slice. Switch to splicing in updated server data, rather than updating in-place, to avoid the race. Change-Id: Ia69895b49cf3f961c58db8e6512ce8b1f5911fd3 Reviewed-on: https://go-review.googlesource.com/c/tools/+/314169 Trust: Robert Findley <rfindley@google.com> Run-TryBot: Robert Findley <rfindley@google.com> gopls-CI: kokoro <noreply+kokoro@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Rebecca Stambler <rstambler@golang.org>
- Loading branch information