From ac0af1135c279f01e8e20176414b4c9c43e7304c Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Thu, 10 Apr 2008 10:42:22 +0000 Subject: [PATCH] (stat): When Vw32_get_true_file_attributes is Qlocal, get attributes only for local files. --- src/w32.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/w32.c b/src/w32.c index e40f9a4b289..bc26d75e78e 100644 --- a/src/w32.c +++ b/src/w32.c @@ -109,6 +109,9 @@ void globals_of_w32 (); extern Lisp_Object Vw32_downcase_file_names; extern Lisp_Object Vw32_generate_fake_inodes; extern Lisp_Object Vw32_get_true_file_attributes; +/* Defined in process.c for its own purpose. */ +extern Lisp_Object Qlocal; + extern int w32_num_mouse_buttons; @@ -2489,6 +2492,8 @@ stat (const char * path, struct stat * buf) } if (!NILP (Vw32_get_true_file_attributes) + && !(EQ (vw32_get_true_file_attributes, Qlocal) && + GetDriveType (name) == DRIVE_FIXED) /* No access rights required to get info. */ && (fh = CreateFile (name, 0, 0, NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, NULL)) -- 2.39.2