cmd/go/internal/imports: resolve symlinks in ScanDir
We were using the mode reported by ReadDir to decide whether each entry is a file, but in the case of symlinks that isn't sufficient: a symlink could point to either a file or a directory, and if it is a file we should treat it as such. Fixes #28107 Change-Id: Icf6e495dce427a7b1124c9cc9f085e40a215c169 Reviewed-on: https://go-review.googlesource.com/c/141097 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
Showing
Please
register
or
sign in
to comment