buildman: Ignore blank lines during size checks
PATCH 1/1 buildman: Ignore blank lines during size checks
Today when parsing the .sizes files we get a warning about an invalid line in the file as it's blank. Solve this by checking that we have a non-blank line prior to processing.
Cc Simon Glass <[email protected]>
Signed-off-by Tom Rini <[email protected]>
--- tools/buildman/builder.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
tools/buildman/builder.py +2 -1
@@ -577,7 +577,8 @@ class Builder: sym = {} for line in fd.readlines(): try: - size, type, name = line[:-1].split() + if line.strip(): + size, type, name = line[:-1].split() except: Print("Invalid line in file '%s': '%s'" % (fname, line[:-1])) continue
Signature · 1 line
2.17.1
PATCH 1/1 buildman: Ignore blank lines during size checks
Hi Tom,
Quoted 10 lines · Tom Rini
Today when parsing the .sizes files we get a warning about an invalid line in the file as it's blank. Solve this by checking that we have a non-blank line prior to processing.
Cc Simon Glass <[email protected]>Signed-off-by Tom Rini <[email protected]>--- tools/buildman/builder.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Reviewed-by Simon Glass <[email protected]>
I haven't seen this problem, but certainly this is safer.
Regards,
Simon