From a2dd2d81948fc09514e70debfc18f95bf8a9d668 Mon Sep 17 00:00:00 2001 From: guoguangwu Date: Sat, 20 Apr 2024 15:00:41 +0800 Subject: [PATCH] fix: close rpmdb Signed-off-by: guoguangwu --- driver/software/rpm.go | 1 + 1 file changed, 1 insertion(+) diff --git a/driver/software/rpm.go b/driver/software/rpm.go index 942ba71..c2c5382 100644 --- a/driver/software/rpm.go +++ b/driver/software/rpm.go @@ -35,6 +35,7 @@ func GetRPMs() ([]software.RPM, error) { if err != nil { return []software.RPM{}, err } + defer db.Close() pkgList, err := db.ListPackages() if err != nil { return []software.RPM{}, err