def exit(self):
        """
        Sometimes client is disconnected and command exits after. So cmdstack is gone
        """
        try:
            self.protocol.cmdstack.pop()
            self.protocol.cmdstack[-1].resume()
        except __HOLE__:
            # cmdstack could be gone already (wget + disconnect)
            pass
dataset/ETHPy150Open cowrie/cowrie/cowrie/core/honeypot.py/HoneyPotCommand.exit