From f02cbcc9f668695e872969ca3473ff096db37bf7 Mon Sep 17 00:00:00 2001 From: wxiaoguang Date: Thu, 2 Mar 2023 22:49:24 +0800 Subject: [PATCH] fix --- cmd/dump.go | 1 + 1 file changed, 1 insertion(+) diff --git a/cmd/dump.go b/cmd/dump.go index c879d2fbee07b..600ec4f32eb08 100644 --- a/cmd/dump.go +++ b/cmd/dump.go @@ -272,6 +272,7 @@ func runDump(ctx *cli.Context) error { fatal("Failed to create tmp file: %v", err) } defer func() { + _ = dbDump.Close() if err := util.Remove(dbDump.Name()); err != nil { log.Warn("Unable to remove temporary file: %s: Error: %v", dbDump.Name(), err) }