Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/dir.cc')
-rw-r--r--winsup/cygwin/dir.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/winsup/cygwin/dir.cc b/winsup/cygwin/dir.cc
index 1b409060e..7323cb388 100644
--- a/winsup/cygwin/dir.cc
+++ b/winsup/cygwin/dir.cc
@@ -67,7 +67,8 @@ opendir (const char *dirname)
goto failed;
}
- if (stat (real_dirname.get_win32 (), &statbuf) == -1)
+ if (stat (myself->rootlen ? dirname : real_dirname.get_win32 (),
+ &statbuf) == -1)
goto failed;
if (!(statbuf.st_mode & S_IFDIR))