From 1df5ab5ee285b3220348ce0cf371b81446d55832 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 20 Jul 2011 22:51:23 +0100 Subject: parse/ConfHandler: Fix multiline variable corruption When parsing multiline variables in conf files, the last character can be accidentally removed. s2 contains new data read from the file which may or may not end with the continuation character. It makes sense to let the next loop iteration strip this if needed. We don't often use multiline expressions in .conf files which is why I'd imagine we haven't noticed this before. Most variables are quoted and its the closing quotation which often disappears. (Bitbake rev: 09a9146262d58dfe4a2ea4270026b90ae33f6c91) Signed-off-by: Richard Purdie --- bitbake/lib/bb/parse/parse_py/ConfHandler.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bitbake/lib/bb/parse') diff --git a/bitbake/lib/bb/parse/parse_py/ConfHandler.py b/bitbake/lib/bb/parse/parse_py/ConfHandler.py index fc239a3540..102c0e93db 100644 --- a/bitbake/lib/bb/parse/parse_py/ConfHandler.py +++ b/bitbake/lib/bb/parse/parse_py/ConfHandler.py @@ -96,7 +96,7 @@ def handle(fn, data, include): s = s.rstrip() if s[0] == '#': continue # skip comments while s[-1] == '\\': - s2 = f.readline()[:-1].strip() + s2 = f.readline().strip() lineno = lineno + 1 s = s[:-1] + s2 feeder(lineno, s, fn, statements) -- cgit v1.2.3-54-g00ecf