From f229083e1e52d2fea46cb7c69be05b5e5f32c680 Mon Sep 17 00:00:00 2001 From: Quentin Machu Date: Mon, 16 Nov 2015 11:33:32 -0500 Subject: [PATCH] database/worker: Remove useless log message --- database/package.go | 1 - worker/worker.go | 8 ++++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/database/package.go b/database/package.go index 73eff607..b93dcade 100644 --- a/database/package.go +++ b/database/package.go @@ -283,7 +283,6 @@ func FindOnePackage(OS, name string, version types.Version, selectedFields []str // FindAllPackagesByNodes finds and returns all packages given by their nodes, selecting the specified fields func FindAllPackagesByNodes(nodes []string, selectedFields []string) ([]*Package, error) { if len(nodes) == 0 { - log.Warning("could not FindAllPackagesByNodes with an empty nodes array.") return []*Package{}, nil } diff --git a/worker/worker.go b/worker/worker.go index 915465b6..998a8690 100644 --- a/worker/worker.go +++ b/worker/worker.go @@ -23,11 +23,11 @@ import ( "os" "strings" - "github.com/coreos/pkg/capnslog" "github.com/coreos/clair/database" "github.com/coreos/clair/utils" cerrors "github.com/coreos/clair/utils/errors" "github.com/coreos/clair/worker/detectors" + "github.com/coreos/pkg/capnslog" ) const ( @@ -125,7 +125,11 @@ func detectContent(ID, path string, parent *database.Layer) (OS string, installe if err != nil { return } - log.Debugf("layer %s: OS is %s.", ID, OS) + if OS != "" { + log.Debugf("layer %s: OS is %s.", ID, OS) + } else { + log.Debugf("layer %s: OS is unknown.", ID) + } packageList, err := detectors.DetectPackages(data) if err != nil {