mirror of
https://github.com/golang/go
synced 2024-11-22 02:44:39 -07:00
godoc: fix initialization issue
R=rsc CC=golang-dev https://golang.org/cl/207111
This commit is contained in:
parent
5aa3a8de6d
commit
ffd0961313
@ -100,7 +100,7 @@ var (
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
func initRoots() {
|
func init() {
|
||||||
goroot = os.Getenv("GOROOT")
|
goroot = os.Getenv("GOROOT")
|
||||||
if goroot == "" {
|
if goroot == "" {
|
||||||
goroot = pathutil.Join(os.Getenv("HOME"), "go")
|
goroot = pathutil.Join(os.Getenv("HOME"), "go")
|
||||||
|
@ -152,7 +152,6 @@ func main() {
|
|||||||
log.Exitf("negative tabwidth %d", *tabwidth)
|
log.Exitf("negative tabwidth %d", *tabwidth)
|
||||||
}
|
}
|
||||||
|
|
||||||
initRoots()
|
|
||||||
readTemplates()
|
readTemplates()
|
||||||
|
|
||||||
if *httpaddr != "" {
|
if *httpaddr != "" {
|
||||||
|
Loading…
Reference in New Issue
Block a user