mirror of
https://github.com/golang/go
synced 2024-11-22 04:14:42 -07:00
cmd/go: fix at least some instances of double compilation
When the packages the tested package depends on don't build, we weren't getting out early. Added a simple check for a successful build to an existing early out. There may be other ways that double compilation arises, but this fixes the one listed in the issue. Fixes #5679 R=golang-dev, rsc CC=golang-dev https://golang.org/cl/13036043
This commit is contained in:
parent
703b897f78
commit
f0fef32383
@ -378,7 +378,7 @@ func runTest(cmd *Command, args []string) {
|
||||
a.deps = append(a.deps, b.action(modeInstall, modeInstall, p))
|
||||
}
|
||||
b.do(a)
|
||||
if !testC {
|
||||
if !testC || a.failed {
|
||||
return
|
||||
}
|
||||
b.init()
|
||||
|
Loading…
Reference in New Issue
Block a user