summaryrefslogtreecommitdiff
path: root/helm-lib.el
diff options
context:
space:
mode:
authorThierry Volpiatto <thierry.volpiatto@gmail.com>2020-05-14 08:43:07 +0200
committerThierry Volpiatto <thierry.volpiatto@gmail.com>2020-05-14 08:44:29 +0200
commite32c715f4afb95e03bf3fd1905f9b1be6a41c3ce (patch)
tree05863465f3613ef79069dd01e82fdd90f57c549a /helm-lib.el
parent16403ddf8a172aca72421f199cf6058bb7a53ad4 (diff)
Fix Windows path error (#2308)
* helm-lib.el (helm-boring-directory-p): Do it.
Diffstat (limited to 'helm-lib.el')
-rw-r--r--helm-lib.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/helm-lib.el b/helm-lib.el
index 2c55e2c3..8abf5a3d 100644
--- a/helm-lib.el
+++ b/helm-lib.el
@@ -740,7 +740,10 @@ end a printable representation of hashtable itself."
"Check if one regexp in BLACK-LIST match DIRECTORY."
(helm-awhile (helm-basedir (directory-file-name
(expand-file-name directory)))
- (when (string= it "/") (cl-return nil))
+ ;; Break at root to avoid infloop, root is / or on Windows
+ ;; C:/ i.e. <volume>:/ (issue #2308).
+ (when (string-match-p "\\`[A-Za-z]?:?/\\'" it)
+ (cl-return nil))
(when (cl-loop for r in black-list
thereis (string-match-p
r (directory-file-name directory)))