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:
parent
a14384370c
commit
26397bff47
|
@ -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:
|
||||
|
|
Loading…
Reference in New Issue