aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOleksandr Redko <oleksandr.red+github@gmail.com>2023-06-29 16:06:19 +0300
committerGopher Robot <gobot@golang.org>2023-07-04 15:31:54 +0000
commite4ed92a355cebc399dc34d33a556f656fa5c7690 (patch)
treeb6d138feddfecf66274d7f5df7ddd12b02649817
parent5c1a15df4141f77ba7c42c2c7c06d6eb22bcda63 (diff)
downloadgo-e4ed92a355cebc399dc34d33a556f656fa5c7690.tar.gz
go-e4ed92a355cebc399dc34d33a556f656fa5c7690.zip
os, syscall: update unreachable link about =C: envs
Change-Id: I185dec133599f9c69fda7563697bbc33e433fb78 Reviewed-on: https://go-review.googlesource.com/c/go/+/507135 TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Ian Lance Taylor <iant@google.com> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> Reviewed-by: Ian Lance Taylor <iant@google.com> Auto-Submit: Ian Lance Taylor <iant@google.com>
-rw-r--r--src/os/env_test.go2
-rw-r--r--src/syscall/env_windows.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/os/env_test.go b/src/os/env_test.go
index 1b9e26594c..5809f4b866 100644
--- a/src/os/env_test.go
+++ b/src/os/env_test.go
@@ -130,7 +130,7 @@ func TestClearenv(t *testing.T) {
defer func(origEnv []string) {
for _, pair := range origEnv {
// Environment variables on Windows can begin with =
- // https://blogs.msdn.com/b/oldnewthing/archive/2010/05/06/10008132.aspx
+ // https://devblogs.microsoft.com/oldnewthing/20100506-00/?p=14133
i := strings.Index(pair[1:], "=") + 1
if err := Setenv(pair[:i], pair[i+1:]); err != nil {
t.Errorf("Setenv(%q, %q) failed during reset: %v", pair[:i], pair[i+1:], err)
diff --git a/src/syscall/env_windows.go b/src/syscall/env_windows.go
index 20d74b51e0..220a005e1a 100644
--- a/src/syscall/env_windows.go
+++ b/src/syscall/env_windows.go
@@ -62,7 +62,7 @@ func Clearenv() {
for _, s := range Environ() {
// Environment variables can begin with =
// so start looking for the separator = at j=1.
- // https://blogs.msdn.com/b/oldnewthing/archive/2010/05/06/10008132.aspx
+ // https://devblogs.microsoft.com/oldnewthing/20100506-00/?p=14133
for j := 1; j < len(s); j++ {
if s[j] == '=' {
Unsetenv(s[0:j])