mirror of
https://github.com/9001/copyparty.git
synced 2025-08-17 17:12:13 -06:00
macos smb: avoid hang on shutdown
This commit is contained in:
parent
4ad4657774
commit
8709d4dba0
|
@ -286,7 +286,10 @@ class MCast(object):
|
||||||
# just give it something
|
# just give it something
|
||||||
ret = list(self.srv.values())[0]
|
ret = list(self.srv.values())[0]
|
||||||
|
|
||||||
if not ret:
|
if ret:
|
||||||
|
t = "new client on {} ({}): {}"
|
||||||
|
self.log(t.format(ret.name, ret.net, cip), 6)
|
||||||
|
else:
|
||||||
t = "could not map client {} to known subnet; maybe forwarded from another network?"
|
t = "could not map client {} to known subnet; maybe forwarded from another network?"
|
||||||
self.log(t.format(cip), 3)
|
self.log(t.format(cip), 3)
|
||||||
|
|
||||||
|
|
|
@ -515,6 +515,7 @@ class SvcHub(object):
|
||||||
|
|
||||||
if hasattr(self, "smbd"):
|
if hasattr(self, "smbd"):
|
||||||
slp = max(slp, time.time() + 0.5)
|
slp = max(slp, time.time() + 0.5)
|
||||||
|
Daemon(self.kill9, a=(1,))
|
||||||
Daemon(self.smbd.stop)
|
Daemon(self.smbd.stop)
|
||||||
|
|
||||||
while time.time() < slp:
|
while time.time() < slp:
|
||||||
|
|
|
@ -960,7 +960,7 @@ def alltrace() -> str:
|
||||||
else:
|
else:
|
||||||
rret += ret
|
rret += ret
|
||||||
|
|
||||||
return "\n".join(rret + bret)
|
return "\n".join(rret + bret) + "\n"
|
||||||
|
|
||||||
|
|
||||||
def start_stackmon(arg_str: str, nid: int) -> None:
|
def start_stackmon(arg_str: str, nid: int) -> None:
|
||||||
|
|
Loading…
Reference in a new issue