cmd/go/internal/vcweb: close the .access file

For #71112

Change-Id: Ifda4fc8de148c42a2154da54b53d7215b9a6faa0
Reviewed-on: https://go-review.googlesource.com/c/go/+/640175
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Auto-Submit: Ian Lance Taylor <iant@golang.org>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Reviewed-by: Michael Matloob <matloob@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
This commit is contained in:
Ian Lance Taylor 2025-01-03 13:49:20 -08:00 committed by Gopher Robot
parent 31cabcf084
commit 5da026354c

View file

@ -63,6 +63,7 @@ func (h *authHandler) Handler(dir string, env []string, logger *log.Logger) (htt
var err error
accessFile, err = fs.Open(path.Join(accessDir, ".access"))
if err == nil {
defer accessFile.Close()
break
}