Skip to content

Commit

Permalink
internal/lsp: split only on the first = for Go environment variables
Browse files Browse the repository at this point in the history
Follow-up from CL 243538.

Change-Id: I15ac8ba738fa5326b18f7b179bed8623f4c57cfd
Reviewed-on: https://go-review.googlesource.com/c/tools/+/243640
Run-TryBot: Rebecca Stambler <[email protected]>
Reviewed-by: Heschi Kreinick <[email protected]>
TryBot-Result: Gobot Gobot <[email protected]>
  • Loading branch information
stamblerre committed Jul 20, 2020
1 parent cf97b7f commit 9cbb971
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/lsp/cache/view.go
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ func (v *View) WriteEnv(ctx context.Context, w io.Writer) error {
fullEnv[k] = v
}
for _, v := range env {
s := strings.Split(v, "=")
s := strings.SplitN(v, "=", 2)
if len(s) != 2 {
continue
}
Expand Down

0 comments on commit 9cbb971

Please sign in to comment.