This bug prevented files such as READMEs etc. from being included in the index.
For instance, now author names recorded in the AUTHORS file can be found with
a godoc query.
R=rsc, r2
CC=golang-dev
https://golang.org/cl/
4005047
// isWhitelisted returns true if a file is on the list
-// of "permitted" files for indexing.
+// of "permitted" files for indexing. The filename must
+// be the directory-local name of the file.
func isWhitelisted(filename string) bool {
key := path.Ext(filename)
if key == "" {
}
goFile = true
- case !includeNonGoFiles || !isWhitelisted(filename):
+ case !includeNonGoFiles || !isWhitelisted(f.Name):
return
}