diff options
author | Alexander Kanavin <alex@linutronix.de> | 2024-11-18 17:26:07 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-11-21 12:16:28 +0000 |
commit | 17f1b80c0619a7648a63cd7be597215ef1e39c60 (patch) | |
tree | a345c6a7fcbe9974ba42e9bd7e6668de3dd2d9a1 /bitbake/bin/bitbake-layers | |
parent | 282cc1ea929f2dc43c095c0029c3b3974bb40566 (diff) | |
download | poky-17f1b80c0619a7648a63cd7be597215ef1e39c60.tar.gz |
bitbake: bitbake-layers: ensure tinfoil.shutdown() gets executed when tinfoil.prepare() fails
https://git.yoctoproject.org/poky/commit/bitbake/bin/bitbake-layers?id=f6de2b033d32c0f92f19f5a4a8c4c8874a00a8f7
erroneously moved tinfoil.prepare() out of try..finally block, where
'finally' contains a tinfoil.shutdown() call.
Without the shutdown, if there is an error in tinfoil.prepare() (such as parsing errors),
the tool locks up, as seen here:
https://valkyrie.yoctoproject.org/#/builders/71/builds/431
(Bitbake rev: 06b8a18339434be8f754e534dacb790a2c9cb91d)
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/bin/bitbake-layers')
-rwxr-xr-x | bitbake/bin/bitbake-layers | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/bitbake/bin/bitbake-layers b/bitbake/bin/bitbake-layers index aebb5100c2..613e675cb0 100755 --- a/bitbake/bin/bitbake-layers +++ b/bitbake/bin/bitbake-layers | |||
@@ -59,13 +59,13 @@ def main(): | |||
59 | plugins = [] | 59 | plugins = [] |
60 | tinfoil = bb.tinfoil.Tinfoil(tracking=True) | 60 | tinfoil = bb.tinfoil.Tinfoil(tracking=True) |
61 | tinfoil.logger.setLevel(logger.getEffectiveLevel()) | 61 | tinfoil.logger.setLevel(logger.getEffectiveLevel()) |
62 | if global_args.force > 1: | 62 | try: |
63 | bbpaths = [] | 63 | if global_args.force > 1: |
64 | else: | 64 | bbpaths = [] |
65 | tinfoil.prepare(True) | 65 | else: |
66 | bbpaths = tinfoil.config_data.getVar('BBPATH').split(':') | 66 | tinfoil.prepare(True) |
67 | 67 | bbpaths = tinfoil.config_data.getVar('BBPATH').split(':') | |
68 | try: | 68 | |
69 | for path in ([topdir] + bbpaths): | 69 | for path in ([topdir] + bbpaths): |
70 | pluginpath = os.path.join(path, 'lib', 'bblayers') | 70 | pluginpath = os.path.join(path, 'lib', 'bblayers') |
71 | bb.utils.load_plugins(logger, plugins, pluginpath) | 71 | bb.utils.load_plugins(logger, plugins, pluginpath) |