aboutsummaryrefslogtreecommitdiffstats
path: root/src/lisp.h
diff options
context:
space:
mode:
authorEli Zaretskii2012-10-12 17:19:54 +0200
committerEli Zaretskii2012-10-12 17:19:54 +0200
commitbb385a92ec4f8f5bbc93641aaa274bd735826574 (patch)
tree8fff4a185dfc74f91d94edc7b45dcd9dacbfbd67 /src/lisp.h
parent605a3df6811c2b3ce9379149cc8fd64fc9846136 (diff)
downloademacs-bb385a92ec4f8f5bbc93641aaa274bd735826574.tar.gz
emacs-bb385a92ec4f8f5bbc93641aaa274bd735826574.zip
Fix bug #12587 with slow startup on MS-Windows with Netlogon service.
src/fileio.c (check_existing): New function. (make_temp_name, Ffile_exists_p, Ffile_writable_p): Call it instead of calling 'stat', when what's needed is to check whether a file exists. This avoids expensive system calls on MS-Windows. src/w32.c (init_environment): Call 'check_existing' instead of 'stat'. src/lread.c (openp) [WINDOWSNT]: Call 'access' instead of 'stat' to determine whether a file exists and is not a directory. src/lisp.h (check_existing): Add prototype.
Diffstat (limited to 'src/lisp.h')
-rw-r--r--src/lisp.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lisp.h b/src/lisp.h
index 62e287561cd..7afe7b373fe 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -3182,6 +3182,7 @@ extern void internal_delete_file (Lisp_Object);
3182extern void syms_of_fileio (void); 3182extern void syms_of_fileio (void);
3183extern Lisp_Object make_temp_name (Lisp_Object, bool); 3183extern Lisp_Object make_temp_name (Lisp_Object, bool);
3184extern Lisp_Object Qdelete_file; 3184extern Lisp_Object Qdelete_file;
3185extern bool check_existing (const char *);
3185 3186
3186/* Defined in search.c. */ 3187/* Defined in search.c. */
3187extern void shrink_regexp_cache (void); 3188extern void shrink_regexp_cache (void);