summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/path.cc
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/path.cc')
-rw-r--r--winsup/cygwin/path.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc
index 057df9acb..1fc9fc3ac 100644
--- a/winsup/cygwin/path.cc
+++ b/winsup/cygwin/path.cc
@@ -361,9 +361,8 @@ fs_info::update (const char *win32_path)
{
char fsname [CYG_MAX_PATH];
char root_dir [CYG_MAX_PATH];
- strncpy (root_dir, win32_path, CYG_MAX_PATH);
- if (!rootdir (root_dir))
+ if (!rootdir (win32_path, root_dir))
{
debug_printf ("Cannot get root component of path %s", win32_path);
clear ();