aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad Howes2024-01-21 10:07:24 +0100
committerEli Zaretskii2024-01-27 12:30:55 +0200
commitfc70eced27832bde0f3702a1f9033d5b81a8d61d (patch)
treeeb70277e9f1523d546b61865496f0cc45dd65549
parent756daa93b3ef7ce33e741ab30000fa397fcd9783 (diff)
downloademacs-fc70eced27832bde0f3702a1f9033d5b81a8d61d.tar.gz
emacs-fc70eced27832bde0f3702a1f9033d5b81a8d61d.zip
Downcase host names in ansi-osc.el to match URL parsing behavior
* lisp/ansi-osc.el (ansi-osc-directory-tracker): Compare with 'system-name' case-insensitively. (Bug#68632) Copyright-paperwork-exempt: yes
-rw-r--r--lisp/ansi-osc.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/ansi-osc.el b/lisp/ansi-osc.el
index 7e686193f69..8dbaeb45132 100644
--- a/lisp/ansi-osc.el
+++ b/lisp/ansi-osc.el
@@ -121,7 +121,8 @@ and `shell-dirtrack-mode'."
121 (let ((url (url-generic-parse-url text))) 121 (let ((url (url-generic-parse-url text)))
122 (when (and (string= (url-type url) "file") 122 (when (and (string= (url-type url) "file")
123 (or (null (url-host url)) 123 (or (null (url-host url))
124 (string= (url-host url) (system-name)))) 124 ;; Use `downcase' to match `url-generic-parse-url' behavior
125 (string= (url-host url) (downcase (system-name)))))
125 (ignore-errors 126 (ignore-errors
126 (cd-absolute (url-unhex-string (url-filename url))))))) 127 (cd-absolute (url-unhex-string (url-filename url)))))))
127 128