From 23029571ec1b1e5670865879fb3e82ef3e1b481d Mon Sep 17 00:00:00 2001 From: Matt Joiner Date: Wed, 1 Sep 2021 15:25:46 +1000 Subject: [PATCH] Fix panic on double Close of sqlite piece completion DB --- storage/sqlite-piece-completion.go | 1 + 1 file changed, 1 insertion(+) diff --git a/storage/sqlite-piece-completion.go b/storage/sqlite-piece-completion.go index 196f1e50..857b97a2 100644 --- a/storage/sqlite-piece-completion.go +++ b/storage/sqlite-piece-completion.go @@ -64,6 +64,7 @@ func (me *sqlitePieceCompletion) Close() (err error) { defer me.mu.Unlock() if me.db != nil { err = me.db.Close() + me.db = nil } return }