mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #27461 from cachedout/clean_context_ioloop
Only clean context if it exists
This commit is contained in:
commit
e8f58a6a3f
1 changed files with 2 additions and 1 deletions
|
@ -312,7 +312,8 @@ class AsyncZeroMQPubChannel(salt.transport.mixins.auth.AESPubClientMixin, salt.t
|
|||
# TODO: Optionally call stream.close() on newer pyzmq? Its broken on some
|
||||
self._stream.io_loop.remove_handler(self._stream.socket)
|
||||
self._stream.socket.close(0)
|
||||
self.context.term()
|
||||
if hasattr(self, 'context'):
|
||||
self.context.term()
|
||||
|
||||
def __del__(self):
|
||||
self.destroy()
|
||||
|
|
Loading…
Add table
Reference in a new issue