From: Michael Albinus Date: Thu, 27 Jul 2023 11:36:48 +0000 (+0200) Subject: Fix problem with null-device in Tramp X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=184fc9b0200cf991c250bb3d6b158eaea2ee7806;p=emacs.git Fix problem with null-device in Tramp * lisp/net/tramp-sh.el (tramp-sh-handle-expand-file-name): `null-device' could be nil. Reported by Richard Copley . --- diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 3ab58c2722e..0cb953e2d80 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -2715,7 +2715,8 @@ the result will be a local, non-Tramp, file name." ;; there could be the false positive "/:". (if (or (and (eq system-type 'windows-nt) (string-match-p - (rx bol (| (: alpha ":") (: (literal null-device) eol))) name)) + (rx bol (| (: alpha ":") (: (literal (or null-device "")) eol))) + name)) (and (not (tramp-tramp-file-p name)) (not (tramp-tramp-file-p dir)))) (tramp-run-real-handler #'expand-file-name (list name dir)) diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 53a80c41680..8b574c4ce93 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -7049,5 +7049,7 @@ If VEC is `tramp-null-hop', return local null device." ;; "/ssh:user1@host:~user2". ;; ;; * Implement file name abbreviation for user and host names. +;; +;; * Implement user and host name completion for multi-hops. ;;; tramp.el ends here