summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/path.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2001-10-05 00:17:57 +0000
committerChristopher Faylor <me@cgf.cx>2001-10-05 00:17:57 +0000
commit32fb80db07f9406e50fca623e9888015e96ccd75 (patch)
treedbd8673a0e37aa156da7c1ac8aa55d45f72d66df /winsup/cygwin/path.cc
parent8af0f81d522b3143ad6fcd5504e4b2ccc7c5b856 (diff)
downloadcygnal-32fb80db07f9406e50fca623e9888015e96ccd75.tar.gz
cygnal-32fb80db07f9406e50fca623e9888015e96ccd75.tar.bz2
cygnal-32fb80db07f9406e50fca623e9888015e96ccd75.zip
* syscalls.cc (stat_worker): Make global. Accept path_conv parameter for
passing information back to caller. * winsup.h: Declare stat_worker. * dir.cc (opendir): Use stat_worker rather than stat and pass path_conv parameter to stat_worker for later inspection. * syslog.cc (syslog): Teach syslog about syslog priorities other than LOG_ERR, LOG_WARNING and LOG_INFO * path.cc (path_conv::check): Don't perform file system or rootdir checks on devices.
Diffstat (limited to 'winsup/cygwin/path.cc')
-rw-r--r--winsup/cygwin/path.cc39
1 files changed, 21 insertions, 18 deletions
diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc
index 07f890f12..b2e1a7975 100644
--- a/winsup/cygwin/path.cc
+++ b/winsup/cygwin/path.cc
@@ -471,8 +471,6 @@ path_conv::check (const char *src, unsigned opt,
if (error)
return;
- update_fs_info (full_path);
-
/* devn should not be a device. If it is, then stop parsing now. */
if (devn != FH_BAD)
{
@@ -480,6 +478,8 @@ path_conv::check (const char *src, unsigned opt,
goto out; /* Found a device. Stop parsing. */
}
+ update_fs_info (full_path);
+
/* Eat trailing slashes */
char *dostail = strchr (full_path, '\0');
@@ -668,24 +668,27 @@ out:
return;
}
- update_fs_info (path);
- if (!fs_name[0])
- {
- set_has_acls (FALSE);
- set_has_buggy_open (FALSE);
- }
- else
+ if (devn == FH_BAD)
{
- set_isdisk ();
- debug_printf ("root_dir(%s), this->path(%s), set_has_acls(%d)",
- root_dir, this->path, fs_flags & FS_PERSISTENT_ACLS);
- if (!allow_smbntsec && is_remote_drive)
- set_has_acls (FALSE);
+ update_fs_info (path);
+ if (!fs_name[0])
+ {
+ set_has_acls (FALSE);
+ set_has_buggy_open (FALSE);
+ }
else
- set_has_acls (fs_flags & FS_PERSISTENT_ACLS);
- /* Known file systems with buggy open calls. Further explanation
- in fhandler.cc (fhandler_disk_file::open). */
- set_has_buggy_open (strcmp (fs_name, "SUNWNFS") == 0);
+ {
+ set_isdisk ();
+ debug_printf ("root_dir(%s), this->path(%s), set_has_acls(%d)",
+ root_dir, this->path, fs_flags & FS_PERSISTENT_ACLS);
+ if (!allow_smbntsec && is_remote_drive)
+ set_has_acls (FALSE);
+ else
+ set_has_acls (fs_flags & FS_PERSISTENT_ACLS);
+ /* Known file systems with buggy open calls. Further explanation
+ in fhandler.cc (fhandler_disk_file::open). */
+ set_has_buggy_open (strcmp (fs_name, "SUNWNFS") == 0);
+ }
}
if (!(opt & PC_FULL))