Handle missing colon (fixes
@@ -629,8 +629,13 @@ def read_header_line(line, pattern=None):
containing a string as value.
'''
- d = {}
+ d = {'name': '', 'unit': '', 'value': '', 'descr': ''}
if pattern is None:
+ if not ':' in line:
+ pattern = (r'\.?(?P<name>[^.]*)\.' +
+ r'(?P<unit>[^\s:]*)' +
+ r'(?P<value>[^:]*)')
+ else:
pattern = (r'\.?(?P<name>[^.]*)\.' +
r'(?P<unit>[^\s:]*)' +
r'(?P<value>[^:]*):' +
