mirror of
https://git.yoctoproject.org/poky
synced 2026-04-27 03:32:12 +02:00
bitbake: process: Allow BBUIEventQueue to exit cleanly
Currently the monitoring thread exits with some error code or runs indefinitely. Allow closure of the pipe its monitoring to have the thread exit cleanly/silently. (Bitbake rev: 930d077637928213e13a07c78fee3bf7a8c37ebf) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
@@ -499,9 +499,14 @@ class BBUIEventQueue:
|
||||
def startCallbackHandler(self):
|
||||
bb.utils.set_process_name("UIEventQueue")
|
||||
while True:
|
||||
self.reader.wait()
|
||||
event = self.reader.get()
|
||||
self.queue_event(event)
|
||||
try:
|
||||
self.reader.wait()
|
||||
event = self.reader.get()
|
||||
self.queue_event(event)
|
||||
except EOFError:
|
||||
# Easiest way to exit is to close the file descriptor to cause an exit
|
||||
break
|
||||
self.reader.close()
|
||||
|
||||
class ConnectionReader(object):
|
||||
|
||||
|
||||
Reference in New Issue
Block a user