]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go: add missing error check
authorEvan Shaw <chickencha@gmail.com>
Mon, 26 Mar 2012 01:52:29 +0000 (09:52 +0800)
committerShenghou Ma <minux.ma@gmail.com>
Mon, 26 Mar 2012 01:52:29 +0000 (09:52 +0800)
R=golang-dev, minux.ma, bradfitz
CC=golang-dev
https://golang.org/cl/5874055

src/cmd/go/get.go

index abaf5ffa0af50b1a3b563e31fc785be3640bcb4a..5db1ff873ba6299a92deeb7011de19b904353a94 100644 (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,