forked from LBRYCommunity/lbry-sdk
stop listening port only if it is not None
This commit is contained in:
parent
6a8963d807
commit
08b4fd6942
1 changed files with 2 additions and 1 deletions
|
@ -256,7 +256,8 @@ class AuthJSONRPCServer(AuthorizedBase):
|
||||||
# ignore INT/TERM signals once shutdown has started
|
# ignore INT/TERM signals once shutdown has started
|
||||||
signal.signal(signal.SIGINT, self._already_shutting_down)
|
signal.signal(signal.SIGINT, self._already_shutting_down)
|
||||||
signal.signal(signal.SIGTERM, self._already_shutting_down)
|
signal.signal(signal.SIGTERM, self._already_shutting_down)
|
||||||
self.listening_port.stopListening()
|
if self.listening_port:
|
||||||
|
self.listening_port.stopListening()
|
||||||
self.looping_call_manager.shutdown()
|
self.looping_call_manager.shutdown()
|
||||||
if self.analytics_manager:
|
if self.analytics_manager:
|
||||||
self.analytics_manager.shutdown()
|
self.analytics_manager.shutdown()
|
||||||
|
|
Loading…
Add table
Reference in a new issue