From e123bf258cf695e319f24b3745e6eec3e252b93d Mon Sep 17 00:00:00 2001 From: Mikhail Klementev Date: Thu, 11 May 2023 20:45:53 +0000 Subject: [PATCH] Fix missing error check --- distro/debian/kernel.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/distro/debian/kernel.go b/distro/debian/kernel.go index 38a53b8..3e6555b 100644 --- a/distro/debian/kernel.go +++ b/distro/debian/kernel.go @@ -37,6 +37,9 @@ func GetDebianKernel(version string) (dk DebianKernel, err error) { regex := `^linux-(image|headers)-[a-z0-9\.\-]*-(amd64|amd64-unsigned)$` packages, err := snapshot.Packages("linux", version, "amd64", regex) + if err != nil { + return + } if len(packages) == 0 { err = ErrNoBinaryPackages return