From 00b4610c4ea12dda9f95b5694eb13cc38b7fd15c Mon Sep 17 00:00:00 2001 From: guangwu Date: Wed, 8 May 2024 11:21:51 +0800 Subject: [PATCH] fix: close file --- gapis/perfetto/android/trace.go | 1 + 1 file changed, 1 insertion(+) diff --git a/gapis/perfetto/android/trace.go b/gapis/perfetto/android/trace.go index 5332cf3d02..726073a748 100644 --- a/gapis/perfetto/android/trace.go +++ b/gapis/perfetto/android/trace.go @@ -201,5 +201,6 @@ func (p *Process) Capture(ctx context.Context, start task.Signal, stop task.Sign if err != nil { return 0, log.Err(ctx, err, fmt.Sprintf("Failed to open %s", tmp)) } + defer fh.Close() return io.Copy(w, fh) }