mirror of
https://git.yoctoproject.org/poky
synced 2026-02-26 19:39:40 +01:00
bitbake: lib/bb/main.py: Shutdown cooker when server isn't foreground
The cooker is added to the BBServer and then detached creating
a copy of the cooker in the process, if the server isn't in
foreground it cause fd leaks on inotify this can be see using
many instances of tinfoil.
Example:
from bb.tinfoil import Tinfoil
while True:
with Tinfoil() as tinfoil:
input("Pre\n")
tinfoil.prepare(config_only=True)
input("Post\n")
[YOCTO #10873]
(Bitbake rev: 2ada2efb057a291eb34c66d975eb339232137956)
Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
509d26f95b
commit
8a3221e6e5
@@ -367,6 +367,7 @@ def start_server(servermodule, configParams, configuration, features):
|
||||
raise
|
||||
if not configParams.foreground:
|
||||
server.detach()
|
||||
cooker.shutdown()
|
||||
cooker.lock.close()
|
||||
return server
|
||||
|
||||
|
||||
Reference in New Issue
Block a user