fix the error code when we fail to open file (#232)

https://github.com/PowerShell/Win32-OpenSSH/issues/934
This commit is contained in:
bagajjal 2017-11-02 22:37:50 -07:00 committed by Manoj Ampalam
parent 65751db59c
commit dce738c33a
1 changed files with 1 additions and 0 deletions

View File

@ -91,6 +91,7 @@ errno_from_Win32Error(int win32_error)
case ERROR_FILE_EXISTS:
return EEXIST;
case ERROR_FILE_NOT_FOUND:
case ERROR_PATH_NOT_FOUND:
return ENOENT;
default:
return win32_error;