* [PATCH] buildhistory_analysis: fix broken list length checks
@ 2012-12-06 11:11 Paul Eggleton
0 siblings, 0 replies; only message in thread
From: Paul Eggleton @ 2012-12-06 11:11 UTC (permalink / raw)
To: openembedded-core
Fix erroneous use of .count instead of len(), which unfortunately is not
reported by Python as an error in a numeric comparison.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
---
meta/lib/oe/buildhistory_analysis.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/meta/lib/oe/buildhistory_analysis.py b/meta/lib/oe/buildhistory_analysis.py
index ad57f00..7b5ee45 100644
--- a/meta/lib/oe/buildhistory_analysis.py
+++ b/meta/lib/oe/buildhistory_analysis.py
@@ -185,7 +185,7 @@ def blob_to_dict(blob):
adict = {}
for line in alines:
splitv = [i.strip() for i in line.split('=',1)]
- if splitv.count > 1:
+ if len(splitv) > 1:
adict[splitv[0]] = splitv[1]
return adict
@@ -231,7 +231,7 @@ def compare_file_lists(alines, blines):
filechanges.append(FileChange(path, FileChange.changetype_ownergroup, oldvalue, newvalue))
# Check symlink target
if newsplitv[0][0] == 'l':
- if splitv.count > 3:
+ if len(splitv) > 3:
oldvalue = splitv[3]
else:
oldvalue = None
--
1.7.10.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-12-06 11:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-06 11:11 [PATCH] buildhistory_analysis: fix broken list length checks Paul Eggleton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox