bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#32266: Cannot add directory names ending in .el with normal-top-leve


From: Robert Pluim
Subject: bug#32266: Cannot add directory names ending in .el with normal-top-level-add-subdirs-to-load-path
Date: Thu, 30 Aug 2018 16:38:54 +0200

Håkon Hægland <hakon.hagland@gmail.com> writes:

> Also, when I look at line #474 of the source
>
> http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/startup.el#n474
>
> I see the following predicate for including a directory:
>
> (not (string-match "\\.elc?\\'" file))

The comment just above says

                 ;; Avoid doing a `stat' when it isn't necessary because
                 ;; that can cause trouble when an NFS server is down.

which has been there for a long time. If an NFS server *is* down, then
that will manifest itself with other files anyway, so I donʼt see why
weʼd need special handling here. I propose:

diff --git i/lisp/startup.el w/lisp/startup.el
index 4eb71abaac..ace4176ac5 100644
--- i/lisp/startup.el
+++ w/lisp/startup.el
@@ -469,9 +469,6 @@ normal-top-level-add-subdirs-to-load-path
            (and (string-match "\\`[[:alnum:]]" file)
                 ;; The lower-case variants of RCS and CVS are for DOS/Windows.
                 (not (member file '("RCS" "CVS" "rcs" "cvs")))
-                ;; Avoid doing a `stat' when it isn't necessary because
-                ;; that can cause trouble when an NFS server is down.
-                (not (string-match "\\.elc?\\'" file))
                 (file-directory-p file)
                 (let ((expanded (expand-file-name file)))
                   (or (file-exists-p (expand-file-name ".nosearch" expanded))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]