Patchwork [30/32] buildhistory_analysis: fix error when version specifier missing

login
register
mail settings
Submitter Scott Garman
Date Aug. 13, 2012, 9:15 p.m.
Message ID <a530aee6d9b2b63ab5fa780b1761eac759e8c833.1344892362.git.scott.a.garman@intel.com>
Download mbox | patch
Permalink /patch/34449/
State New
Headers show

Comments

Scott Garman - Aug. 13, 2012, 9:15 p.m.
From: Paul Eggleton <paul.eggleton@linux.intel.com>

Passing None to split_versions() will raise an exception, so check that
the version is specified before passing it in.

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/lib/oe/buildhistory_analysis.py |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/meta/lib/oe/buildhistory_analysis.py b/meta/lib/oe/buildhistory_analysis.py
index 313416c..29dc4a9 100644
--- a/meta/lib/oe/buildhistory_analysis.py
+++ b/meta/lib/oe/buildhistory_analysis.py
@@ -272,7 +272,7 @@  def compare_pkg_lists(astr, bstr):
         if k in depverb:
             dva = depvera[k]
             dvb = depverb[k]
-            if dva != dvb:
+            if dva and dvb and dva != dvb:
                 if bb.utils.vercmp(split_version(dva), split_version(dvb)) < 0:
                     remove.append(k)