From cdab2fc520d49d98df470b82d486671a40075447 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Tue, 9 Feb 2021 10:13:15 +0300 Subject: [PATCH] [#316] cmd/cli: Close location database after locode info cmd execution Signed-off-by: Leonard Lyubich --- cmd/neofs-cli/modules/util.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cmd/neofs-cli/modules/util.go b/cmd/neofs-cli/modules/util.go index d5f2aff62d..75b403bbdc 100644 --- a/cmd/neofs-cli/modules/util.go +++ b/cmd/neofs-cli/modules/util.go @@ -156,6 +156,8 @@ var ( return err } + defer targetDB.Close() + record, err := locodedb.LocodeRecord(targetDB, locodeInfoCode) if err != nil { return err