diff options
| author | Michael Albinus | 2021-11-11 11:55:15 +0100 |
|---|---|---|
| committer | Michael Albinus | 2021-11-11 11:55:15 +0100 |
| commit | 7aad73febfd10627996edb1d6264e2abac4d2c65 (patch) | |
| tree | 8af22fa47761208b500dd9b67fc5edcf237ef74d | |
| parent | 9a59d9017bf50f41dc1aa0778d0b350040866eb1 (diff) | |
| parent | 6dae01ad6da1bcbced062c0d46a6759c7a0570e4 (diff) | |
| download | emacs-7aad73febfd10627996edb1d6264e2abac4d2c65.tar.gz emacs-7aad73febfd10627996edb1d6264e2abac4d2c65.zip | |
Merge from origin/emacs-28
6dae01ad6d Fix tramp-compat-file-name-concat (Bug#51754)
| -rw-r--r-- | lisp/net/tramp-compat.el | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el index 213ab5857c5..fbc3d684ce8 100644 --- a/lisp/net/tramp-compat.el +++ b/lisp/net/tramp-compat.el | |||
| @@ -386,14 +386,17 @@ CONDITION can also be a list of error conditions." | |||
| 386 | (if (fboundp 'file-name-concat) | 386 | (if (fboundp 'file-name-concat) |
| 387 | #'file-name-concat | 387 | #'file-name-concat |
| 388 | (lambda (directory &rest components) | 388 | (lambda (directory &rest components) |
| 389 | (unless (null directory) | 389 | (let ((components (cl-remove-if (lambda (el) |
| 390 | (let ((components (delq nil components)) | 390 | (or (null el) (equal "" el))) |
| 391 | file-name-handler-alist) | 391 | components)) |
| 392 | (if (null components) | 392 | file-name-handler-alist) |
| 393 | directory | 393 | (if (null components) |
| 394 | (tramp-compat-file-name-concat | 394 | directory |
| 395 | (concat (file-name-as-directory directory) (car components)) | 395 | (apply #'tramp-compat-file-name-concat |
| 396 | (cdr components)))))))) | 396 | (concat (unless (or (equal "" directory) (null directory)) |
| 397 | (file-name-as-directory directory)) | ||
| 398 | (car components)) | ||
| 399 | (cdr components))))))) | ||
| 397 | 400 | ||
| 398 | (dolist (elt (all-completions "tramp-compat-" obarray 'functionp)) | 401 | (dolist (elt (all-completions "tramp-compat-" obarray 'functionp)) |
| 399 | (put (intern elt) 'tramp-suppress-trace t)) | 402 | (put (intern elt) 'tramp-suppress-trace t)) |