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:
authorChristopher Faylor <me@cgf.cx>2005-02-27 07:30:08 +0300
committerChristopher Faylor <me@cgf.cx>2005-02-27 07:30:08 +0300
commitd61925786a19f2ee513c969ad7cb421a7db762b7 (patch)
tree3ca1430f75e6982f822d708ca5f469f3a4950f73 /winsup/cygwin/fhandler_mem.cc
parent78d9eaa5eac0e037206b481c4c5512936d53524d (diff)
* sigproc.cc (_pinfo::set_ctty): Move function
* pinfo.cc (_pinfo::set_ctty): to here. * fhandler_mem.cc (fhandler_dev_mem::fstat): Don't fill out structure if this is an on-disk device rather than an "auto" device. * fhandler_raw.cc (fhandler_dev_raw::fstat): Ditto. * path.cc (normalize_posix_path): Don't treat a standalone '//' as introducing a UNC path. (normalize_win32_path): Ditto.
Diffstat (limited to 'winsup/cygwin/fhandler_mem.cc')
-rw-r--r--winsup/cygwin/fhandler_mem.cc13
1 files changed, 8 insertions, 5 deletions
diff --git a/winsup/cygwin/fhandler_mem.cc b/winsup/cygwin/fhandler_mem.cc
index 4c873d758..296ef8693 100644
--- a/winsup/cygwin/fhandler_mem.cc
+++ b/winsup/cygwin/fhandler_mem.cc
@@ -402,12 +402,15 @@ int
fhandler_dev_mem::fstat (struct __stat64 *buf)
{
fhandler_base::fstat (buf);
- buf->st_mode = S_IFCHR;
- if (wincap.has_physical_mem_access ())
- buf->st_mode |= S_IRUSR | S_IWUSR |
- S_IRGRP | S_IWGRP |
- S_IROTH | S_IWOTH;
buf->st_blksize = getpagesize ();
+ if (is_auto_device ())
+ {
+ buf->st_mode = S_IFCHR;
+ if (wincap.has_physical_mem_access ())
+ buf->st_mode |= S_IRUSR | S_IWUSR |
+ S_IRGRP | S_IWGRP |
+ S_IROTH | S_IWOTH;
+ }
return 0;
}