From: Lars Ingebrigtsen Date: Wed, 28 Jul 2021 16:10:59 +0000 (+0200) Subject: Make byte-recompile-directory less brittle X-Git-Tag: emacs-28.0.90~1669 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c9c1460342a5aadf3819ceb6ee5ac28c14760fce;p=emacs.git Make byte-recompile-directory less brittle * lisp/emacs-lisp/bytecomp.el (byte-recompile-directory): Don't interpret files named "~" as $HOME (bug#49758). --- diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index 1b64a06fe42..a6e7e03cb0a 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el @@ -1857,8 +1857,8 @@ also be compiled." (while directories (setq directory (car directories)) (message "Checking %s..." directory) - (dolist (file (directory-files directory)) - (let ((source (expand-file-name file directory))) + (dolist (source (directory-files directory t)) + (let ((file (file-name-nondirectory source))) (if (file-directory-p source) (and (not (member file '("RCS" "CVS"))) (not (eq ?\. (aref file 0)))