From 63a149a18fd9437576cdb81520a2246b14705e57 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Tue, 31 Jan 2006 16:10:29 +0000 Subject: * path.cc (cwdstuff::set): Don't set win32 error, only POSIX errno. --- winsup/cygwin/path.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'winsup/cygwin/path.cc') diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc index 73ea90831..f23debb8a 100644 --- a/winsup/cygwin/path.cc +++ b/winsup/cygwin/path.cc @@ -3978,8 +3978,9 @@ cwdstuff::set (const char *win32_cwd, const char *posix_cwd, bool doit) /* When calling SetCurrentDirectory for a non-existant dir on a Win9x share, it returns ERROR_INVALID_FUNCTION. */ if (GetLastError () == ERROR_INVALID_FUNCTION) - SetLastError (ERROR_FILE_NOT_FOUND); - __seterrno (); + set_errno (ENOENT); + else + __seterrno (); goto out; } } -- cgit v1.2.3