• Eli Zaretskii's avatar
    Fix bug #12587 with slow startup on MS-Windows with Netlogon service. · bb385a92
    Eli Zaretskii authored
     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.
    bb385a92
w32.c 184 KB