Skip to content

Commit

Permalink
Improve SFTP debug log output when sending EOF response
Browse files Browse the repository at this point in the history
  • Loading branch information
ronf committed Aug 23, 2018
1 parent 340aee9 commit 29b30f6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion asyncssh/sftp.py
Expand Up @@ -3192,7 +3192,10 @@ def _process_packet(self, pkttype, pktid, packet):
except SFTPError as exc:
return_type = FXP_STATUS

self.logger.debug1('Sending error: %s', str(exc.reason))
if exc.code == FX_EOF:
self.logger.debug1('Sending EOF')
else:
self.logger.debug1('Sending error: %s', str(exc.reason))

result = UInt32(exc.code) + String(exc.reason) + String(exc.lang)
except NotImplementedError as exc:
Expand Down

0 comments on commit 29b30f6

Please sign in to comment.