diff options
| -rw-r--r-- | lisp/net/tramp-adb.el | 5 | ||||
| -rw-r--r-- | lisp/net/tramp-ftp.el | 5 | ||||
| -rw-r--r-- | lisp/net/tramp-gvfs.el | 2 | ||||
| -rw-r--r-- | lisp/net/tramp-smb.el | 5 | ||||
| -rw-r--r-- | lisp/net/tramp.el | 53 |
5 files changed, 38 insertions, 32 deletions
diff --git a/lisp/net/tramp-adb.el b/lisp/net/tramp-adb.el index 36374f88e0d..00c6ad43ea1 100644 --- a/lisp/net/tramp-adb.el +++ b/lisp/net/tramp-adb.el | |||
| @@ -173,8 +173,9 @@ It is used for TCP/IP devices." | |||
| 173 | ;;;###tramp-autoload | 173 | ;;;###tramp-autoload |
| 174 | (defsubst tramp-adb-file-name-p (filename) | 174 | (defsubst tramp-adb-file-name-p (filename) |
| 175 | "Check if it's a filename for ADB." | 175 | "Check if it's a filename for ADB." |
| 176 | (let ((v (tramp-dissect-file-name filename))) | 176 | (and (tramp-tramp-file-p filename) |
| 177 | (string= (tramp-file-name-method v) tramp-adb-method))) | 177 | (string= (tramp-file-name-method (tramp-dissect-file-name filename)) |
| 178 | tramp-adb-method))) | ||
| 178 | 179 | ||
| 179 | ;;;###tramp-autoload | 180 | ;;;###tramp-autoload |
| 180 | (defun tramp-adb-file-name-handler (operation &rest args) | 181 | (defun tramp-adb-file-name-handler (operation &rest args) |
diff --git a/lisp/net/tramp-ftp.el b/lisp/net/tramp-ftp.el index 983f168ddb4..5d8b56e218f 100644 --- a/lisp/net/tramp-ftp.el +++ b/lisp/net/tramp-ftp.el | |||
| @@ -183,8 +183,9 @@ pass to the OPERATION." | |||
| 183 | ;;;###tramp-autoload | 183 | ;;;###tramp-autoload |
| 184 | (defsubst tramp-ftp-file-name-p (filename) | 184 | (defsubst tramp-ftp-file-name-p (filename) |
| 185 | "Check if it's a filename that should be forwarded to Ange-FTP." | 185 | "Check if it's a filename that should be forwarded to Ange-FTP." |
| 186 | (string= (tramp-file-name-method (tramp-dissect-file-name filename)) | 186 | (and (tramp-tramp-file-p filename) |
| 187 | tramp-ftp-method)) | 187 | (string= (tramp-file-name-method (tramp-dissect-file-name filename)) |
| 188 | tramp-ftp-method))) | ||
| 188 | 189 | ||
| 189 | ;;;###tramp-autoload | 190 | ;;;###tramp-autoload |
| 190 | (add-to-list 'tramp-foreign-file-name-handler-alist | 191 | (add-to-list 'tramp-foreign-file-name-handler-alist |
diff --git a/lisp/net/tramp-gvfs.el b/lisp/net/tramp-gvfs.el index c150edf3f13..fb687f0d7bd 100644 --- a/lisp/net/tramp-gvfs.el +++ b/lisp/net/tramp-gvfs.el | |||
| @@ -2088,7 +2088,7 @@ This uses \"avahi-browse\" in case D-Bus is not enabled in Avahi." | |||
| 2088 | ;;; TODO: | 2088 | ;;; TODO: |
| 2089 | 2089 | ||
| 2090 | ;; * (Customizable) unmount when exiting Emacs. See tramp-archive.el. | 2090 | ;; * (Customizable) unmount when exiting Emacs. See tramp-archive.el. |
| 2091 | 2091 | ;; | |
| 2092 | ;; * Host name completion for existing mount points (afp-server, | 2092 | ;; * Host name completion for existing mount points (afp-server, |
| 2093 | ;; smb-server, google-drive, nextcloud) or via smb-network or network. | 2093 | ;; smb-server, google-drive, nextcloud) or via smb-network or network. |
| 2094 | ;; | 2094 | ;; |
diff --git a/lisp/net/tramp-smb.el b/lisp/net/tramp-smb.el index a97b8017300..eadb4029b54 100644 --- a/lisp/net/tramp-smb.el +++ b/lisp/net/tramp-smb.el | |||
| @@ -321,8 +321,9 @@ This can be used to disable echo etc." | |||
| 321 | ;;;###tramp-autoload | 321 | ;;;###tramp-autoload |
| 322 | (defsubst tramp-smb-file-name-p (filename) | 322 | (defsubst tramp-smb-file-name-p (filename) |
| 323 | "Check if it's a filename for SMB servers." | 323 | "Check if it's a filename for SMB servers." |
| 324 | (string= (tramp-file-name-method (tramp-dissect-file-name filename)) | 324 | (and (tramp-tramp-file-p filename) |
| 325 | tramp-smb-method)) | 325 | (string= (tramp-file-name-method (tramp-dissect-file-name filename)) |
| 326 | tramp-smb-method))) | ||
| 326 | 327 | ||
| 327 | ;;;###tramp-autoload | 328 | ;;;###tramp-autoload |
| 328 | (defun tramp-smb-file-name-handler (operation &rest args) | 329 | (defun tramp-smb-file-name-handler (operation &rest args) |
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 8362d787525..97f931a4a44 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -3301,31 +3301,34 @@ User is always nil." | |||
| 3301 | (numchase-limit 20) | 3301 | (numchase-limit 20) |
| 3302 | symlink-target) | 3302 | symlink-target) |
| 3303 | (with-parsed-tramp-file-name result v1 | 3303 | (with-parsed-tramp-file-name result v1 |
| 3304 | (with-tramp-file-property v1 v1-localname "file-truename" | 3304 | ;; We cache only the localname. |
| 3305 | (while (and (setq symlink-target (file-symlink-p result)) | 3305 | (tramp-make-tramp-file-name |
| 3306 | (< numchase numchase-limit)) | 3306 | v1 |
| 3307 | (setq numchase (1+ numchase) | 3307 | (with-tramp-file-property v1 v1-localname "file-truename" |
| 3308 | result | 3308 | (while (and (setq symlink-target (file-symlink-p result)) |
| 3309 | (with-parsed-tramp-file-name (expand-file-name result) v2 | 3309 | (< numchase numchase-limit)) |
| 3310 | (tramp-make-tramp-file-name | 3310 | (setq numchase (1+ numchase) |
| 3311 | v2 | 3311 | result |
| 3312 | (funcall | 3312 | (with-parsed-tramp-file-name (expand-file-name result) v2 |
| 3313 | (if (tramp-compat-file-name-quoted-p v2-localname) | 3313 | (tramp-make-tramp-file-name |
| 3314 | 'tramp-compat-file-name-quote 'identity) | 3314 | v2 |
| 3315 | 3315 | (funcall | |
| 3316 | (if (stringp symlink-target) | 3316 | (if (tramp-compat-file-name-quoted-p v2-localname) |
| 3317 | (if (file-remote-p symlink-target) | 3317 | 'tramp-compat-file-name-quote 'identity) |
| 3318 | (let (file-name-handler-alist) | 3318 | |
| 3319 | (tramp-compat-file-name-quote symlink-target)) | 3319 | (if (stringp symlink-target) |
| 3320 | (expand-file-name | 3320 | (if (file-remote-p symlink-target) |
| 3321 | symlink-target (file-name-directory v2-localname))) | 3321 | (let (file-name-handler-alist) |
| 3322 | v2-localname)) | 3322 | (tramp-compat-file-name-quote symlink-target)) |
| 3323 | 'nohop))) | 3323 | (expand-file-name |
| 3324 | (when (>= numchase numchase-limit) | 3324 | symlink-target (file-name-directory v2-localname))) |
| 3325 | (tramp-error | 3325 | v2-localname)) |
| 3326 | v1 'file-error | 3326 | 'nohop))) |
| 3327 | "Maximum number (%d) of symlinks exceeded" numchase-limit))) | 3327 | (when (>= numchase numchase-limit) |
| 3328 | (directory-file-name result)))))) | 3328 | (tramp-error |
| 3329 | v1 'file-error | ||
| 3330 | "Maximum number (%d) of symlinks exceeded" numchase-limit))) | ||
| 3331 | (file-local-name (directory-file-name result)))))))) | ||
| 3329 | 3332 | ||
| 3330 | (defun tramp-handle-find-backup-file-name (filename) | 3333 | (defun tramp-handle-find-backup-file-name (filename) |
| 3331 | "Like `find-backup-file-name' for Tramp files." | 3334 | "Like `find-backup-file-name' for Tramp files." |