Commit e62e595e authored by Robert Griesemer's avatar Robert Griesemer

godoc/zip.go: fix another zip file system bug

Don't report that a directory was found just because we found
the list index where the directory would be if it were there...

R=iant
CC=golang-dev
https://golang.org/cl/4812051
parent fa497796
......@@ -198,5 +198,9 @@ func (z zipList) lookup(name string) (index int, exact bool) {
if j < 0 {
return -1, false
}
return i + j, false
if strings.HasPrefix(z[j].Name, name) {
return i + j, false
}
return -1, false
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment