ENOTDIR should be translated into NO_SUCH_FILE -- openssh does it, and there really isn't any better mapping for it
This commit is contained in:
Robey Pointer 2005-12-16 10:00:02 -08:00
parent a14384370c
commit 26397bff47
1 changed files with 1 additions and 1 deletions

View File

@ -118,7 +118,7 @@ class SFTPServer (BaseSFTP, SubsystemHandler):
if e == errno.EACCES:
# permission denied
return SFTP_PERMISSION_DENIED
elif e == errno.ENOENT:
elif (e == errno.ENOENT) or (e == errno.ENOTDIR):
# no such file
return SFTP_NO_SUCH_FILE
else: