cmd/go: add missing error check

R=golang-dev, minux.ma, bradfitz
CC=golang-dev
https://golang.org/cl/5874055
This commit is contained in:
Evan Shaw 2012-03-26 09:52:29 +08:00 committed by Shenghou Ma
parent 7b8f8bf5b5
commit c26b504b0d
1 changed files with 3 additions and 0 deletions

View File

@ -227,6 +227,9 @@ func downloadPackage(p *Package) error {
if p.build.SrcRoot != "" {
// Directory exists. Look for checkout along path to src.
vcs, rootPath, err = vcsForDir(p)
if err != nil {
return err
}
repo = "<local>" // should be unused; make distinctive
} else {
// Analyze the import path to determine the version control system,