1
0
mirror of https://github.com/golang/go synced 2024-11-14 20:00:31 -07:00

os: add File.Close for TestFileStatNUL

Change-Id: I9f8b0beed16f38d71055cdc7606306d93fb535c2
Reviewed-on: https://go-review.googlesource.com/c/go/+/622655
Reviewed-by: Cherry Mui <cherryyz@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
This commit is contained in:
changwang ma 2024-10-25 23:41:42 +08:00 committed by Gopher Robot
parent c77ca70f44
commit 7a256adbaf

View File

@ -990,6 +990,8 @@ func TestFileStatNUL(t *testing.T) {
if err != nil {
t.Fatal(err)
}
defer f.Close()
fi, err := f.Stat()
if err != nil {
t.Fatal(err)