summaryrefslogtreecommitdiffstats
path: root/bitbake
diff options
context:
space:
mode:
authorJoshua Watt <jpewhacker@gmail.com>2019-09-26 14:23:53 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-09-27 13:02:19 +0100
commit2ac500a609e10b0f1aba698f756a0fc9d022240f (patch)
tree358d349ecaa8342ee24ee5c8ec342351295a0db0 /bitbake
parent1805574559c3862eaf1fd4ff9a9fc8a05556a8ce (diff)
downloadpoky-2ac500a609e10b0f1aba698f756a0fc9d022240f.tar.gz
bitbake: hashserv: Don't daemonize server process
The hash server process is terminated and waited on with join(), so it should not be a daemon. Daemonizing it cause races with the server cleanup, especially in the selftest because the process may not have terminated and cleanup up its socket before the test cleanup runs and tries to do it. [YOCTO #13542] (Bitbake rev: 7c829675581818f92d57056b57fbd3880829b6bd) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rw-r--r--bitbake/lib/bb/cooker.py1
-rw-r--r--bitbake/lib/hashserv/tests.py1
2 files changed, 0 insertions, 2 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index 0c540028ae..20ef04d3ff 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -399,7 +399,6 @@ class BBCooker:
399 self.hashservaddr = "unix://%s/hashserve.sock" % self.data.getVar("TOPDIR") 399 self.hashservaddr = "unix://%s/hashserve.sock" % self.data.getVar("TOPDIR")
400 self.hashserv = hashserv.create_server(self.hashservaddr, dbfile, sync=False) 400 self.hashserv = hashserv.create_server(self.hashservaddr, dbfile, sync=False)
401 self.hashserv.process = multiprocessing.Process(target=self.hashserv.serve_forever) 401 self.hashserv.process = multiprocessing.Process(target=self.hashserv.serve_forever)
402 self.hashserv.process.daemon = True
403 self.hashserv.process.start() 402 self.hashserv.process.start()
404 self.data.setVar("BB_HASHSERVE", self.hashservaddr) 403 self.data.setVar("BB_HASHSERVE", self.hashservaddr)
405 self.databuilder.origdata.setVar("BB_HASHSERVE", self.hashservaddr) 404 self.databuilder.origdata.setVar("BB_HASHSERVE", self.hashservaddr)
diff --git a/bitbake/lib/hashserv/tests.py b/bitbake/lib/hashserv/tests.py
index 6584ff57b4..a5472a996d 100644
--- a/bitbake/lib/hashserv/tests.py
+++ b/bitbake/lib/hashserv/tests.py
@@ -32,7 +32,6 @@ class TestHashEquivalenceServer(object):
32 32
33 self.server = create_server(self.get_server_addr(), self.dbfile) 33 self.server = create_server(self.get_server_addr(), self.dbfile)
34 self.server_thread = multiprocessing.Process(target=self._run_server) 34 self.server_thread = multiprocessing.Process(target=self._run_server)
35 self.server_thread.daemon = True
36 self.server_thread.start() 35 self.server_thread.start()
37 self.client = create_client(self.server.address) 36 self.client = create_client(self.server.address)
38 37