]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: deadlock tests now work with GOMAXPROCS>1
authorDmitriy Vyukov <dvyukov@google.com>
Sat, 2 Mar 2013 06:41:53 +0000 (10:41 +0400)
committerDmitriy Vyukov <dvyukov@google.com>
Sat, 2 Mar 2013 06:41:53 +0000 (10:41 +0400)
Fixes #4826.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/7434046

src/pkg/runtime/crash_test.go

index b2db1d7b95c93dccf07a485e07da440497c150f4..5f84cb5a2fbed86501c719fa2fc8f783237ae3c8 100644 (file)
@@ -37,15 +37,7 @@ func executeTest(t *testing.T, templ string, data interface{}) string {
        }
        f.Close()
 
-       // Deadlock tests hang with GOMAXPROCS>1.  Issue 4826.
-       cmd := exec.Command("go", "run", src)
-       for _, s := range os.Environ() {
-               if strings.HasPrefix(s, "GOMAXPROCS") {
-                       continue
-               }
-               cmd.Env = append(cmd.Env, s)
-       }
-       got, _ := cmd.CombinedOutput()
+       got, _ := exec.Command("go", "run", src).CombinedOutput()
        return string(got)
 }