1
0
mirror of https://github.com/golang/go synced 2024-11-12 06:20:22 -07:00

godoc: fix vet warnings for untagged struct literals

src/cmd/godoc/filesystem.go:337:10: os.PathError struct literal uses untagged fields
src/cmd/godoc/filesystem.go:355:10: os.PathError struct literal uses untagged fields

R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/5820046
This commit is contained in:
Andrew Gerrand 2012-03-14 13:19:39 +11:00
parent 5659826e43
commit adcb508359

View File

@ -334,7 +334,7 @@ func (ns nameSpace) Open(path string) (readSeekCloser, error) {
}
}
if err == nil {
err = &os.PathError{"open", path, os.ErrNotExist}
err = &os.PathError{Op: "open", Path: path, Err: os.ErrNotExist}
}
return nil, err
}
@ -352,7 +352,7 @@ func (ns nameSpace) stat(path string, f func(FileSystem, string) (os.FileInfo, e
}
}
if err == nil {
err = &os.PathError{"stat", path, os.ErrNotExist}
err = &os.PathError{Op: "stat", Path: path, Err: os.ErrNotExist}
}
return nil, err
}