示例#1
0
文件: ssh.py 项目: Roguelazer/Tron
    def channelClosed(self, channel):
        if not channel.conn:
            log.warning("Channel %r failed to open", channel.id)
            # Channel has no connection, so we were still trying to open it
            # The normal error handling won't notify us since the channel never successfully opened.
            channel.openFailed(None)

        connection.SSHConnection.channelClosed(self, channel)
示例#2
0
文件: ssh.py 项目: swipswaps/Tron
    def channelClosed(self, channel):
        if not channel.conn:
            log.warning("Channel %r failed to open", channel.id)
            # Channel has no connection, so we were still trying to open it
            # The normal error handling won't notify us since the channel never successfully opened.
            channel.openFailed(None)

        connection.SSHConnection.channelClosed(self, channel)
示例#3
0
 def channelClosed(self, channel):
     # Work around a bug in Conch 0.8 - channelClosed tries to close
     # channels which are not really open yet. This is fixed since twisted's
     # SVN revision 20700.
     # FIXME: Remove after upgrade to newer twisted.
     if channel in self.channelsToRemoteChannel:
         connection.SSHConnection.channelClosed(self, channel)
     else:
         # See http://twistedmatrix.com/trac/ticket/2782.
         channel.openFailed(ConchError("Service stopped"))