Skip to content

Commit

Permalink
gopls/internal/golang: close open file
Browse files Browse the repository at this point in the history
Found while thinking about typestate.

Change-Id: Ia98ace4782be34d1201f0ce5c8e536314fc494d7
Reviewed-on: https://go-review.googlesource.com/c/tools/+/563155
Reviewed-by: Robert Findley <rfindley@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Commit-Queue: Alan Donovan <adonovan@google.com>
Auto-Submit: Alan Donovan <adonovan@google.com>
  • Loading branch information
adonovan authored and gopherbot committed Feb 12, 2024
1 parent f0ef3c6 commit 50b4f1b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions gopls/internal/golang/gc_annotations.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ func GCOptimizationDetails(ctx context.Context, snapshot *cache.Snapshot, mp *me
if err != nil {
return nil, err
}
tmpFile.Close() // ignore error
defer os.Remove(tmpFile.Name())

outDirURI := protocol.URIFromPath(outDir)
Expand Down

0 comments on commit 50b4f1b

Please sign in to comment.