mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 18:40:39 -08:00
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.
This commit is contained in:
parent
b421decc52
commit
5c207910c4
5 changed files with 60 additions and 16 deletions
|
|
@ -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
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue