diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-08-31 17:23:16 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-08-31 23:30:03 +0100 |
commit | e2ca45646eed986b9b0a965110b7771cfbc26710 (patch) | |
tree | ba7e70a78060e116d1e35035893799d74cf8a728 /bitbake/lib/prserv | |
parent | 6e1ab28e94bf71ffd6a7fe5ba9346c22716dbfa9 (diff) | |
download | poky-e2ca45646eed986b9b0a965110b7771cfbc26710.tar.gz |
bitbake: prserv/serv: Gracefully handle the PR server exiting quickly
If the server exits quickly its PID may no longer exist. Handle
this gracefully.
(Bitbake rev: c1b00a9265fa4146b8db8b7d03a51bf2bfcf9f51)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/prserv')
-rw-r--r-- | bitbake/lib/prserv/serv.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/bitbake/lib/prserv/serv.py b/bitbake/lib/prserv/serv.py index dfcbd2058f..6a99728c4f 100644 --- a/bitbake/lib/prserv/serv.py +++ b/bitbake/lib/prserv/serv.py | |||
@@ -492,7 +492,11 @@ def auto_shutdown(): | |||
492 | PRServerConnection(host, port).terminate() | 492 | PRServerConnection(host, port).terminate() |
493 | except: | 493 | except: |
494 | logger.critical("Stop PRService %s:%d failed" % (host,port)) | 494 | logger.critical("Stop PRService %s:%d failed" % (host,port)) |
495 | os.waitpid(singleton.prserv.pid, 0) | 495 | |
496 | try: | ||
497 | os.waitpid(singleton.prserv.pid, 0) | ||
498 | except ChildProcessError: | ||
499 | pass | ||
496 | singleton = None | 500 | singleton = None |
497 | 501 | ||
498 | def ping(host, port): | 502 | def ping(host, port): |