[oe-commits] [bitbake] 06/09: server/process: Ensure socket has a timeout set

git at git.openembedded.org git at git.openembedded.org
Mon Jan 28 17:07:17 UTC 2019


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch 1.40
in repository bitbake.

commit 833d95f538c007c27c6eb8d8f2f97094dc2b1a41
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
AuthorDate: Fri Dec 14 17:49:16 2018 +0000

    server/process: Ensure socket has a timeout set
    
    We're seeing hangs in oe-selftest where server startup and shutdown are
    racing. The assumption was a connect would timeout however no timeout is
    set which can leave processes hanging. Set a short timeout for
    the connection to avoid this.
    
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 lib/bb/server/process.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/bb/server/process.py b/lib/bb/server/process.py
index 1a6a826..f7d0726 100644
--- a/lib/bb/server/process.py
+++ b/lib/bb/server/process.py
@@ -474,6 +474,8 @@ def connectProcessServer(sockname, featureset):
     readfd = writefd = readfd1 = writefd1 = readfd2 = writefd2 = None
     eq = command_chan_recv = command_chan = None
 
+    sock.settimeout(2)
+
     try:
         try:
             os.chdir(os.path.dirname(sockname))

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list