1
0
Fork 0

patman: fix series-notes handling for buildman

A patman series with a 'Series-notes' section causes
buildman to crash with:

    self.series.notes += self.section
    TypeError: cannot concatenate 'str' and 'list' objects

Fix by initializing series.notes as a one-element array
rather than a scalar.

Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
Acked-by: Simon Glass <sjg@chromium.org>
Tested-by: Simon Glass <sjg@chromium.org>
utp
Albert ARIBAUD 2016-02-02 10:24:53 +01:00 committed by Simon Glass
parent 5f3f7b79db
commit 070b781b2b
1 changed files with 4 additions and 1 deletions

View File

@ -69,7 +69,10 @@ class Series(dict):
# Otherwise just set the value
elif name in valid_series:
self[name] = value
if name=="notes":
self[name] = [value]
else:
self[name] = value
else:
raise ValueError("In %s: line '%s': Unknown 'Series-%s': valid "
"options are %s" % (commit.hash, line, name,