diff options
-rw-r--r-- | paramiko/channel.py | 2 | ||||
-rw-r--r-- | sites/www/changelog.rst | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/paramiko/channel.py b/paramiko/channel.py index 2757450b..25326cab 100644 --- a/paramiko/channel.py +++ b/paramiko/channel.py @@ -961,7 +961,7 @@ class Channel(ClosingContextManager): m = self._send_eof() finally: self.lock.release() - if m is not None: + if m is not None and self.transport is not None: self.transport._send_user_message(m) def shutdown_read(self): diff --git a/sites/www/changelog.rst b/sites/www/changelog.rst index f5fcb85d..9d730283 100644 --- a/sites/www/changelog.rst +++ b/sites/www/changelog.rst @@ -2,6 +2,9 @@ Changelog ========= +- :bug:`-` Check for ``None`` transport members inside + `~paramiko.channel.Channel` when closing the channel; this likely doesn't + come up much in the real world, but was causing warnings in the test suite. - :release:`3.4.1 <2024-08-11>` - :release:`3.3.2 <2024-08-11>` - :bug:`2419` (fixed in :issue:`2421`) Massage our import of the TripleDES |