diff options
author | Eli Zaretskii <eliz@gnu.org> | 2012-12-14 16:05:01 +0200 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2012-12-14 16:05:01 +0200 |
commit | 5c207910c4899af1c547b0e508692d846c145d48 (patch) | |
tree | b3516d3332d126e8add66cfff68c11ac7ed187b8 /nt | |
parent | b421decc52e07a3c56b2b259321867bc352f5173 (diff) | |
download | emacs-5c207910c4899af1c547b0e508692d846c145d48.tar.gz |
Speed up most calls to 'stat' and 'lstat' on MS-Windows.
src/w32.c (stat_worker): If w32_stat_get_owner_group is zero, do not
try to get accurate owner and group information from NT file
security APIs. This is to make most callers of 'stat' and
'lstat', which don't need that information, much faster.
src/dired.c (Ffile_attributes) [WINDOWSNT]: Set
w32_stat_get_owner_group to a non-zero value, to request accurate
owner and group information from 'lstat'.
nt/inc/sys/stat.h: Declare w32_stat_get_owner_group.
Diffstat (limited to 'nt')
-rw-r--r-- | nt/ChangeLog | 4 | ||||
-rw-r--r-- | nt/inc/sys/stat.h | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/nt/ChangeLog b/nt/ChangeLog index 4a82a97b58e..56e986498ae 100644 --- a/nt/ChangeLog +++ b/nt/ChangeLog @@ -1,3 +1,7 @@ +2012-12-14 Eli Zaretskii <eliz@gnu.org> + + * inc/sys/stat.h: Declare w32_stat_get_owner_group. + 2012-12-13 Juanma Barranquero <lekktu@gmail.com> * config.nt: Sync with autogen/config.in. diff --git a/nt/inc/sys/stat.h b/nt/inc/sys/stat.h index b673b80a0e3..fb56b7cab40 100644 --- a/nt/inc/sys/stat.h +++ b/nt/inc/sys/stat.h @@ -98,6 +98,10 @@ struct stat { char st_gname[260]; }; +/* Internal variable for asking 'stat'/'lstat' to produce accurate + info about owner and group of files. */ +extern int w32_stat_get_owner_group; + /* Prevent redefinition by other headers, e.g. wchar.h. */ #define _STAT_DEFINED |