Mercurial > hg > truffle
diff mx/outputparser.py @ 4354:3abb137806c7
Merge.
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Tue, 17 Jan 2012 23:35:39 +0100 |
parents | 063ea022532c |
children | 3aab15f42934 |
line wrap: on
line diff
--- a/mx/outputparser.py Tue Jan 17 23:35:21 2012 +0100 +++ b/mx/outputparser.py Tue Jan 17 23:35:39 2012 +0100 @@ -37,7 +37,7 @@ self.matchers.append(matcher) def parse(self, vm, cmd, cwd=None, vmbuild=None): - ret = [{}] + ret = [] def parseLine(line): anyMatch = False @@ -45,7 +45,7 @@ parsed = matcher.parse(line.strip()) if parsed: anyMatch = True - if matcher.startNewLine and len(ret[0]) > 0: + if len(ret) is 0 or (matcher.startNewLine and len(ret[len(ret)-1]) > 0): ret.append({}) ret[len(ret)-1].update(parsed) if anyMatch :