]> code.ossystems Code Review - openembedded-core.git/commitdiff
base.bbclass: Work even when there's no PNBLACKLIST entries
authorPeter Seebach <peter.seebach@windriver.com>
Thu, 16 Aug 2012 16:50:45 +0000 (11:50 -0500)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 17 Aug 2012 09:54:02 +0000 (10:54 +0100)
It turns out that the result of getVarFlags is not a list, it's
a dict. So "getVarFlags(...) or []" does not reliably produce
something with a .items. This escaped detection because our
local build environment never ends up running builds without
PNBLACKLIST entries.

Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/base.bbclass

index 840ddbcc93f019fcd2b003a7c58ed56650874f9e..acc3217b394a4b34f408f76f3ff62b746192801c 100644 (file)
@@ -175,7 +175,7 @@ def preferred_ml_updates(d):
 
     versions = []
     providers = []
-    blacklists = d.getVarFlags('PNBLACKLIST') or []
+    blacklists = d.getVarFlags('PNBLACKLIST') or {}
     for v in d.keys():
         if v.startswith("PREFERRED_VERSION_"):
             versions.append(v)