mirror of
https://git.yoctoproject.org/poky
synced 2026-04-04 23:02:22 +02:00
bitbake: process: log odd unlink events with bitbake.sock
Log when the socket file already exists and is removed before recreating a new socket. Log when unlinking the socket file failed. (Bitbake rev: 9779fad4d9e2540b24bb91cfa38fc1984402bef2) Signed-off-by: Frank de Brabander <debrabander@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit cfd7c9899f988bab6d9fe7bbfbdb60603fb5ed34) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
075101eee1
commit
bfa114bfa8
@@ -248,8 +248,8 @@ class ProcessServer():
|
||||
# Remove the socket file so we don't get any more connections to avoid races
|
||||
try:
|
||||
os.unlink(self.sockname)
|
||||
except:
|
||||
pass
|
||||
except Exception as err:
|
||||
serverlog("Removing socket file '%s' failed (%s)" % (self.sockname, err))
|
||||
self.sock.close()
|
||||
|
||||
try:
|
||||
@@ -532,6 +532,7 @@ def execServer(lockfd, readypipeinfd, lockname, sockname, server_timeout, xmlrpc
|
||||
|
||||
# Create server control socket
|
||||
if os.path.exists(sockname):
|
||||
serverlog("WARNING: removing existing socket file '%s'" % sockname)
|
||||
os.unlink(sockname)
|
||||
|
||||
sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
|
||||
|
||||
Reference in New Issue
Block a user