From a68bd32b5a9cfc6b3ca0fe5fe960944bb7443700 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 16 Jul 2025 09:45:18 -0700 Subject: [PATCH] Avoid syscall in dir-locals--all-files * lisp/files.el (dir-locals--all-files): Omit an unnecessary call to file-directory-p. (cherry picked from commit b282cb98e498ded876b87e5e48fe74b8c45156ea) --- lisp/files.el | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lisp/files.el b/lisp/files.el index ab3126a55bc..83842aed116 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -4697,10 +4697,7 @@ those in the first." (list file-2 file-1))) (when (and f (file-readable-p f) - ;; FIXME: Aren't file-regular-p and - ;; file-directory-p mutually exclusive? - (file-regular-p f) - (not (file-directory-p f))) + (file-regular-p f)) (push f out))) out))) -- 2.39.5