emacs-diffs
[Top][All Lists]
Advanced

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

master 0ddbacc: Don't override load-path in require-theme


From: Basil L. Contovounesios
Subject: master 0ddbacc: Don't override load-path in require-theme
Date: Fri, 5 Mar 2021 06:06:11 -0500 (EST)

branch: master
commit 0ddbacca7d45e68a3235489de94293335891806c
Author: Basil L. Contovounesios <contovob@tcd.ie>
Commit: Basil L. Contovounesios <contovob@tcd.ie>

    Don't override load-path in require-theme
    
    * lisp/custom.el (require-theme): Open-code 'require' error, because
    binding load-path can prevent other libraries from loading on error,
    such as debug.el, which gives a misleading error.  (Bug#45068)
---
 lisp/custom.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lisp/custom.el b/lisp/custom.el
index b9fccce..85e5d65 100644
--- a/lisp/custom.el
+++ b/lisp/custom.el
@@ -1223,8 +1223,8 @@ provide FEATURE, signal an error.  This cannot be 
suppressed."
            (file (locate-file (symbol-name feature) path '(".elc" ".el"))))
       (and file (require feature (file-name-sans-extension file) noerror))))
    ((not noerror)
-    (let (load-path)
-      (require feature)))))
+    (signal 'file-missing `("Cannot open load file" "No such file or directory"
+                            ,(symbol-name feature))))))
 
 (defcustom custom-safe-themes '(default)
   "Themes that are considered safe to load.



reply via email to

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