emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/tramp 7cc8cf5: Tramp ELPA version 2.5.1.4 released


From: ELPA Syncer
Subject: [elpa] externals/tramp 7cc8cf5: Tramp ELPA version 2.5.1.4 released
Date: Fri, 29 Oct 2021 08:57:32 -0400 (EDT)

branch: externals/tramp
commit 7cc8cf567f9d8f28efb9abea3419f9bd42017e07
Author: Michael Albinus <michael.albinus@gmx.de>
Commit: Michael Albinus <michael.albinus@gmx.de>

    Tramp ELPA version 2.5.1.4 released
---
 Makefile            |   1 +
 README              |  40 ++++++------
 test/tramp-tests.el | 182 +++++++++++++++++++++++++++++++++++++---------------
 texi/tramp.texi     |  47 +++++++++++---
 texi/trampver.texi  |   2 +-
 tramp-adb.el        |  75 +++++++++++-----------
 tramp-archive.el    |   2 +-
 tramp-cache.el      |  28 ++------
 tramp-fuse.el       |  76 ++++++++++++++++++----
 tramp-gvfs.el       |  36 ++---------
 tramp-rclone.el     |   1 +
 tramp-sh.el         |  14 ++--
 tramp-smb.el        |   2 +-
 tramp-sshfs.el      |  64 +++++++++---------
 tramp-sudoedit.el   |   5 +-
 tramp.el            | 132 +++++++++++++++++++++++--------------
 trampver.el         |   6 +-
 17 files changed, 432 insertions(+), 281 deletions(-)

diff --git a/Makefile b/Makefile
index 92d3c53..839d0aa 100644
--- a/Makefile
+++ b/Makefile
@@ -50,6 +50,7 @@ clean:
 
 # This target is for the maintainer only.
 sync:
+       cp -p $(SOURCE_DIR)/README-ELPA README
        cp -p $(SOURCE_DIR)/lisp/tramp-adb.el tramp-adb.el
        cp -p $(SOURCE_DIR)/lisp/tramp-archive.el tramp-archive.el
        cp -p $(SOURCE_DIR)/lisp/tramp-cache.el tramp-cache.el
diff --git a/README b/README
index 6ab3411..6214832 100644
--- a/README
+++ b/README
@@ -1,35 +1,37 @@
-Tramp stands for `Transparent Remote (file) Access, Multiple
-Protocol'.  This package provides remote file editing, similar to
-Ange-FTP.
+Installing TRAMP via GNU ELPA
+*****************************
+
+Tramp stands for "Transparent Remote (file) Access, Multiple Protocol".
+This package provides remote file editing, similar to Ange-FTP.
 
 The difference is that Ange-FTP uses FTP to transfer files between the
-local and the remote host, whereas Tramp uses a combination of `rsh'
-and `rcp' or other work-alike programs, such as `ssh'/`scp'.
+local and the remote host, whereas Tramp uses a combination of 'rsh' and
+'rcp' or other work-alike programs, such as 'ssh'/'scp'.
 
 A remote file name has always the syntax
 
-  /method:user%domain@host#port:/path/to/file
+     /method:user%domain@host#port:/path/to/file
 
-Most of the parts are optional, read the manual for details.
+Most of the parts are optional, read the manual
+<https://www.gnu.org/software/tramp/> for details.
 
 Tramp must be compiled for the Emacs version you are running.  If you
-experience compatibility error messages for the Tramp package, or if
-you use another major Emacs version than the version Tramp has been
-installed with, you must recompile the package (<version> is the
-version of the Tramp package):
+experience compatibility error messages for the Tramp package, or if you
+use another major Emacs version than the version Tramp has been
+installed with, you must recompile the package:
 
-1. Remove all byte-compiled Tramp files
+   * Remove all byte-compiled Tramp files
 
-  # rm -f ~/.emacs.d/elpa/tramp-<version>/tramp*.elc
+          $ rm -f ~/.emacs.d/elpa/tramp-2.5.1.4/tramp*.elc
 
-2. Start Emacs with Tramp's source files
+   * Start Emacs with Tramp's source files
 
-  # emacs -L ~/.emacs.d/elpa/tramp-<version> -l tramp
+          $ emacs -L ~/.emacs.d/elpa/tramp-2.5.1.4 -l tramp
 
-This should not give you the error.
+     This should not give you the error.
 
-3. Recompile the Tramp package *with this running Emacs instance*
+   * Recompile the Tramp package *with this running Emacs instance*
 
-  M-x tramp-recompile-elpa
+          M-x tramp-recompile-elpa
 
-Afterwards, you must restart Emacs.
+     Afterwards, you must restart Emacs.
diff --git a/test/tramp-tests.el b/test/tramp-tests.el
index 28aadbb..061aebb 100644
--- a/test/tramp-tests.el
+++ b/test/tramp-tests.el
@@ -69,6 +69,7 @@
 (defvar tramp-connection-properties)
 (defvar tramp-copy-size-limit)
 (defvar tramp-display-escape-sequence-regexp)
+(defvar tramp-fuse-unmount-on-cleanup)
 (defvar tramp-inline-compress-start-size)
 (defvar tramp-persistency-file-name)
 (defvar tramp-remote-path)
@@ -2785,7 +2786,7 @@ This tests also `file-directory-p' and 
`file-accessible-directory-p'."
             :type 'file-already-exists)
            (should (file-directory-p tmp-name1))
            (should (file-accessible-directory-p tmp-name1))
-           (when (tramp--test-supports-file-modes-p)
+           (when (tramp--test-supports-set-file-modes-p)
              (should (equal (format "%#o" unusual-file-mode-1)
                             (format "%#o" (file-modes tmp-name1)))))
            (should-error
@@ -2795,7 +2796,7 @@ This tests also `file-directory-p' and 
`file-accessible-directory-p'."
              (make-directory tmp-name2 'parents))
            (should (file-directory-p tmp-name2))
            (should (file-accessible-directory-p tmp-name2))
-           (when (tramp--test-supports-file-modes-p)
+           (when (tramp--test-supports-set-file-modes-p)
              (should (equal (format "%#o" unusual-file-mode-2)
                             (format "%#o" (file-modes tmp-name2)))))
            ;; If PARENTS is non-nil, `make-directory' shall not
@@ -3158,7 +3159,20 @@ This tests also `file-directory-p' and 
`file-accessible-directory-p'."
                  (regexp-opt (directory-files tmp-name1))
                  (length (directory-files tmp-name1)))))))
 
-           ;; Check error case.
+           ;; Check error cases.
+           (when (and (tramp--test-supports-set-file-modes-p)
+                      ;; With "sshfs", directories with zero file
+                      ;; modes are still "accessible".
+                      (not (tramp--test-sshfs-p))
+                      ;; A directory is always accessible for user "root".
+                      (not (zerop (tramp-compat-file-attribute-user-id
+                                   (file-attributes tmp-name1)))))
+             (set-file-modes tmp-name1 0)
+             (with-temp-buffer
+               (should-error
+                (insert-directory tmp-name1 nil)
+                :type 'file-error))
+             (set-file-modes tmp-name1 #o777))
            (delete-directory tmp-name1 'recursive)
            (with-temp-buffer
              (should-error
@@ -3371,9 +3385,21 @@ This tests also `access-file', `file-readable-p',
                       (tramp-get-remote-gid tramp-test-vec 'integer)))
              (delete-file tmp-name1))
 
+           (when (tramp--test-supports-set-file-modes-p)
+             (write-region "foo" nil tmp-name1)
+             ;; A file is always accessible for user "root".
+             (when (not (zerop (tramp-compat-file-attribute-user-id
+                                (file-attributes tmp-name1))))
+               (set-file-modes tmp-name1 0)
+               (should-error
+                (access-file tmp-name1 "error")
+                :type 'file-error)
+               (set-file-modes tmp-name1 #o777))
+             (delete-file tmp-name1))
            (should-error
             (access-file tmp-name1 "error")
             :type tramp-file-missing)
+
            ;; `file-ownership-preserved-p' should return t for
            ;; non-existing files.
            (when test-file-ownership-preserved-p
@@ -3601,7 +3627,8 @@ They might differ only in time attributes or directory 
size."
   "Check `file-modes'.
 This tests also `file-executable-p', `file-writable-p' and `set-file-modes'."
   (skip-unless (tramp--test-enabled))
-  (skip-unless (tramp--test-supports-file-modes-p))
+  (skip-unless (tramp--test-supports-set-file-modes-p))
+
   (dolist (quoted (if (tramp--test-expensive-test) '(nil t) '(nil)))
     (let ((tmp-name1 (tramp--test-make-temp-name nil quoted))
          (tmp-name2 (tramp--test-make-temp-name nil quoted)))
@@ -3936,7 +3963,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
             (make-symbolic-link tmp-name2 tmp-name1)
             (should (file-symlink-p tmp-name1))
             (if (tramp--test-smb-p)
-                ;; The symlink command of `smbclient' detects the
+                ;; The symlink command of "smbclient" detects the
                 ;; cycle already.
                 (should-error
                  (make-symbolic-link tmp-name1 tmp-name2)
@@ -4047,6 +4074,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
 (ert-deftest tramp-test24-file-acl ()
   "Check that `file-acl' and `set-file-acl' work proper."
   (skip-unless (tramp--test-enabled))
+  ;; The following test checks also whether `set-file-modes' will work.
   (skip-unless (file-acl tramp-test-temporary-file-directory))
   (skip-unless (not (tramp--test-crypt-p)))
 
@@ -4414,8 +4442,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
   "Check `process-file'."
   :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
-  (skip-unless (or (tramp--test-adb-p) (tramp--test-sh-p) 
(tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (skip-unless (tramp--test-supports-processes-p))
 
   (dolist (quoted (if (tramp--test-expensive-test) '(nil t) '(nil)))
     (let* ((tmp-name (tramp--test-make-temp-name nil quoted))
@@ -4457,7 +4484,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
              (write-region "foo" nil tmp-name)
              (should (file-exists-p tmp-name))
              (should (zerop (process-file "ls" nil t nil fnnd)))
-             ;; `ls' could produce colorized output.
+             ;; "ls" could produce colorized output.
              (goto-char (point-min))
              (while
                  (re-search-forward tramp-display-escape-sequence-regexp nil t)
@@ -4468,7 +4495,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
              ;; Second run.  The output must be appended.
              (goto-char (point-max))
              (should (zerop (process-file "ls" nil t t fnnd)))
-             ;; `ls' could produce colorized output.
+             ;; "ls" could produce colorized output.
              (goto-char (point-min))
              (while
                  (re-search-forward tramp-display-escape-sequence-regexp nil t)
@@ -4481,7 +4508,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
        ;; Cleanup.
        (ignore-errors (delete-file tmp-name))))))
 
-;; Must be a command, because used as `sigusr' handler.
+;; Must be a command, because used as `sigusr1' handler.
 (defun tramp--test-timeout-handler (&rest _ignore)
   "Timeout handler, reporting a failed test."
   (interactive)
@@ -4495,8 +4522,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
   "Check `start-file-process'."
   :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
-  (skip-unless (or (tramp--test-adb-p) (tramp--test-sh-p) 
(tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (skip-unless (tramp--test-supports-processes-p))
 
   (dolist (quoted (if (tramp--test-expensive-test) '(nil t) '(nil)))
     (let ((default-directory tramp-test-temporary-file-directory)
@@ -4561,6 +4587,26 @@ This tests also `make-symbolic-link', `file-truename' 
and `add-name-to-file'."
        ;; Cleanup.
        (ignore-errors (delete-process proc)))
 
+      ;; "telnet" and "sshfs" do not cooperate with disabled filter.
+      (unless (or (tramp--test-telnet-p) (tramp--test-sshfs-p))
+       (unwind-protect
+           (with-temp-buffer
+             (setq proc (start-file-process "test3" (current-buffer) "cat"))
+             (should (processp proc))
+             (should (equal (process-status proc) 'run))
+             (set-process-filter proc t)
+             (process-send-string proc "foo\n")
+             (process-send-eof proc)
+             ;; Read output.
+             (with-timeout (10 (tramp--test-timeout-handler))
+               (while (process-live-p proc)
+                 (while (accept-process-output proc 0 nil t))))
+             ;; No output due to process filter.
+             (should (= (point-min) (point-max))))
+
+         ;; Cleanup.
+         (ignore-errors (delete-process proc))))
+
       ;; Process connection type.
       (when (and (tramp--test-sh-p)
                 (not (tramp-direct-async-process-p))
@@ -4591,7 +4637,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
                  (if (and (memq process-connection-type '(nil pipe))
                            (not (tramp--test-macos-p)))
                       ;; On macOS, there is always newline conversion.
-                     ;; `telnet' converts \r to <CR><NUL> if `crlf'
+                     ;; "telnet" converts \r to <CR><NUL> if `crlf'
                      ;; flag is FALSE.  See telnet(1) man page.
                      "66\n6F\n6F\n0D\\(\n00\\)?\n0A\n"
                    "66\n6F\n6F\n0A\\(\n00\\)?\n0A\n")
@@ -4655,8 +4701,7 @@ If UNSTABLE is non-nil, the test is tagged as 
`:unstable'."
   "Check `make-process'."
   :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
-  (skip-unless (or (tramp--test-adb-p) (tramp--test-sh-p) 
(tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (skip-unless (tramp--test-supports-processes-p))
   ;; `make-process' supports file name handlers since Emacs 27.
   (skip-unless (tramp--test-emacs27-p))
 
@@ -4734,6 +4779,30 @@ If UNSTABLE is non-nil, the test is tagged as 
`:unstable'."
        ;; Cleanup.
        (ignore-errors (delete-process proc)))
 
+      ;; "telnet" and "sshfs" do not cooperate with disabled filter.
+      (unless (or (tramp--test-telnet-p) (tramp--test-sshfs-p))
+       (unwind-protect
+           (with-temp-buffer
+             (setq proc
+                   (with-no-warnings
+                     (make-process
+                      :name "test3" :buffer (current-buffer) :command '("cat")
+                      :filter t
+                      :file-handler t)))
+             (should (processp proc))
+             (should (equal (process-status proc) 'run))
+             (process-send-string proc "foo\n")
+             (process-send-eof proc)
+             ;; Read output.
+             (with-timeout (10 (tramp--test-timeout-handler))
+               (while (process-live-p proc)
+                 (while (accept-process-output proc 0 nil t))))
+             ;; No output due to process filter.
+             (should (= (point-min) (point-max))))
+
+         ;; Cleanup.
+         (ignore-errors (delete-process proc))))
+
       ;; Process sentinel.
       (unwind-protect
          (with-temp-buffer
@@ -4759,7 +4828,7 @@ If UNSTABLE is non-nil, the test is tagged as 
`:unstable'."
        ;; Cleanup.
        (ignore-errors (delete-process proc)))
 
-      ;; Process with stderr buffer.  `telnet' does not cooperate with
+      ;; Process with stderr buffer.  "telnet" does not cooperate with
       ;; three processes.
       (unless (or (tramp--test-telnet-p) (tramp-direct-async-process-p))
        (let ((stderr (generate-new-buffer "*stderr*")))
@@ -4859,7 +4928,7 @@ If UNSTABLE is non-nil, the test is tagged as 
`:unstable'."
                                   '(nil pipe))
                              (not (tramp--test-macos-p)))
                         ;; On macOS, there is always newline conversion.
-                       ;; `telnet' converts \r to <CR><NUL> if `crlf'
+                       ;; "telnet" converts \r to <CR><NUL> if `crlf'
                        ;; flag is FALSE.  See telnet(1) man page.
                        "66\n6F\n6F\n0D\\(\n00\\)?\n0A\n"
                      "66\n6F\n6F\n0A\\(\n00\\)?\n0A\n")
@@ -4935,11 +5004,11 @@ INPUT, if non-nil, is a string sent to the process."
   "Check `shell-command'."
   :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
+  (skip-unless (tramp--test-supports-processes-p))
   ;; Prior Emacs 27, `shell-file-name' was hard coded as "/bin/sh" for
   ;; remote processes in Emacs.  That doesn't work for tramp-adb.el.
-  (skip-unless (or (and (tramp--test-adb-p) (tramp--test-emacs27-p))
-                  (tramp--test-sh-p) (tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (when (tramp--test-adb-p)
+    (skip-unless (tramp--test-emacs27-p)))
 
   (dolist (quoted (if (tramp--test-expensive-test) '(nil t) '(nil)))
     (let ((tmp-name (tramp--test-make-temp-name nil quoted))
@@ -4963,7 +5032,7 @@ INPUT, if non-nil, is a string sent to the process."
               this-shell-command
               (format "ls %s" (file-name-nondirectory tmp-name))
               (current-buffer))
-             ;; `ls' could produce colorized output.
+             ;; "ls" could produce colorized output.
              (goto-char (point-min))
              (while
                  (re-search-forward tramp-display-escape-sequence-regexp nil t)
@@ -5037,8 +5106,7 @@ INPUT, if non-nil, is a string sent to the process."
   :tags '(:expensive-test :unstable)
   (skip-unless (tramp--test-enabled))
   (skip-unless nil)
-  (skip-unless (or (tramp--test-adb-p) (tramp--test-sh-p) 
(tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (skip-unless (tramp--test-supports-processes-p))
   ;; Prior Emacs 27, `shell-command-dont-erase-buffer' wasn't working properly.
   (skip-unless (tramp--test-emacs27-p))
 
@@ -5359,11 +5427,11 @@ Use direct async.")
   "Check that connection-local `explicit-shell-file-name' is set."
   :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
+  (skip-unless (tramp--test-supports-processes-p))
   ;; Prior Emacs 27, `shell-file-name' was hard coded as "/bin/sh" for
   ;; remote processes in Emacs.  That doesn't work for tramp-adb.el.
-  (skip-unless (or (and (tramp--test-adb-p) (tramp--test-emacs27-p))
-                  (tramp--test-sh-p) (tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (when (tramp--test-adb-p)
+    (skip-unless (tramp--test-emacs27-p)))
   ;; Since Emacs 26.1.
   (skip-unless (and (fboundp 'connection-local-set-profile-variables)
                    (fboundp 'connection-local-set-profiles)))
@@ -5418,8 +5486,8 @@ Use direct async.")
 (ert-deftest tramp-test35-exec-path ()
   "Check `exec-path' and `executable-find'."
   (skip-unless (tramp--test-enabled))
-  (skip-unless (or (tramp--test-adb-p) (tramp--test-sh-p) 
(tramp--test-sshfs-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (skip-unless (tramp--test-supports-processes-p))
+  (skip-unless (tramp--test-supports-set-file-modes-p))
   ;; Since Emacs 27.1.
   (skip-unless (fboundp 'exec-path))
 
@@ -5440,6 +5508,7 @@ Use direct async.")
          ;; found.
          (write-region "foo" nil tmp-name)
          (should (file-exists-p tmp-name))
+
          (set-file-modes tmp-name #o777)
          (should (file-executable-p tmp-name))
          (should
@@ -5884,10 +5953,7 @@ Use direct async.")
          tramp-allow-unsafe-temporary-files
           (inhibit-message t)
          ;; tramp-rclone.el and tramp-sshfs.el cache the mounted files.
-         (tramp-cleanup-connection-hook
-          (append
-           (and (tramp--test-fuse-p) '(tramp-fuse-unmount))
-           tramp-cleanup-connection-hook))
+         (tramp-fuse-unmount-on-cleanup t)
           auto-save-default
          noninteractive)
 
@@ -6127,6 +6193,10 @@ This does not support external Emacs calls."
   (string-equal
    "mock" (file-remote-p tramp-test-temporary-file-directory 'method)))
 
+(defun tramp--test-out-of-band-p ()
+  "Check, whether an out-of-band method is used."
+  (tramp-method-out-of-band-p tramp-test-vec 1))
+
 (defun tramp--test-rclone-p ()
   "Check, whether the remote host is offered by rclone.
 This requires restrictions of file name syntax."
@@ -6182,13 +6252,13 @@ This does not support special file names."
 (defun tramp--test-windows-nt-and-out-of-band-p ()
   "Check, whether the locale host runs MS Windows and an out-of-band method.
 This does not support utf8 based file transfer."
-  (and (eq system-type 'windows-nt)
-       (tramp-method-out-of-band-p tramp-test-vec 1)))
+  (and (tramp--test-windows-nt-p)
+       (tramp--test-out-of-band-p)))
 
 (defun tramp--test-windows-nt-or-smb-p ()
   "Check, whether the locale or remote host runs MS Windows.
 This requires restrictions of file name syntax."
-  (or (eq system-type 'windows-nt)
+  (or (tramp--test-windows-nt-p)
       (tramp--test-smb-p)))
 
 (defun tramp--test-smb-p ()
@@ -6196,8 +6266,13 @@ This requires restrictions of file name syntax."
 This requires restrictions of file name syntax."
   (tramp-smb-file-name-p tramp-test-temporary-file-directory))
 
-(defun tramp--test-supports-file-modes-p ()
-  "Return whether the method under test supports file modes."
+(defun tramp--test-supports-processes-p ()
+  "Return whether the method under test supports external processes."
+  (and (or (tramp--test-adb-p) (tramp--test-sh-p) (tramp--test-sshfs-p))
+       (not (tramp--test-crypt-p))))
+
+(defun tramp--test-supports-set-file-modes-p ()
+  "Return whether the method under test supports setting file modes."
   ;; "smb" does not unless the SMB server supports "posix" extensions.
   ;; "adb" does not unless the Android device is rooted.
   (or (tramp--test-sh-p) (tramp--test-sshfs-p) (tramp--test-sudoedit-p)
@@ -6300,9 +6375,9 @@ This requires restrictions of file name syntax."
            (kill-buffer buffer)
 
            ;; `substitute-in-file-name' could return different
-           ;; values.  For `adb', there could be strange file
+           ;; values.  For "adb", there could be strange file
            ;; permissions preventing overwriting a file.  We don't
-           ;; care in this testcase.
+           ;; care in this test case.
            (dolist (elt files)
              (let ((file1
                     (substitute-in-file-name (expand-file-name elt tmp-name1)))
@@ -6468,7 +6543,7 @@ This requires restrictions of file name syntax."
 
 (ert-deftest tramp-test41-special-characters-with-stat ()
   "Check special characters in file names.
-Use the `stat' command."
+Use the \"stat\" command."
   :tags '(:expensive-test)
   (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 287s
   (skip-unless (tramp--test-enabled))
@@ -6487,7 +6562,7 @@ Use the `stat' command."
 
 (ert-deftest tramp-test41-special-characters-with-perl ()
   "Check special characters in file names.
-Use the `perl' command."
+Use the \"perl\" command."
   :tags '(:expensive-test)
   (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 266s
   (skip-unless (tramp--test-enabled))
@@ -6509,7 +6584,7 @@ Use the `perl' command."
 
 (ert-deftest tramp-test41-special-characters-with-ls ()
   "Check special characters in file names.
-Use the `ls' command."
+Use the \"ls\" command."
   :tags '(:expensive-test)
   (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 287s
   (skip-unless (tramp--test-enabled))
@@ -6591,14 +6666,14 @@ Use the `ls' command."
 
 (ert-deftest tramp-test42-utf8-with-stat ()
   "Check UTF8 encoding in file names and file contents.
-Use the `stat' command."
+Use the \"stat\" command."
   :tags '(:expensive-test)
   (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 595s
   (skip-unless (tramp--test-enabled))
   (skip-unless (tramp--test-sh-p))
   (skip-unless (not (tramp--test-docker-p)))
   (skip-unless (not (tramp--test-rsync-p)))
-  (skip-unless (not (tramp--test-windows-nt-and-out-of-band-p)))
+  (skip-unless (not (tramp--test-out-of-band-p))) ; SLOW
   (skip-unless (not (tramp--test-ksh-p)))
   (skip-unless (not (tramp--test-crypt-p)))
   ;; We cannot use `tramp-test-vec', because this fails during compilation.
@@ -6614,14 +6689,14 @@ Use the `stat' command."
 
 (ert-deftest tramp-test42-utf8-with-perl ()
   "Check UTF8 encoding in file names and file contents.
-Use the `perl' command."
+Use the \"perl\" command."
   :tags '(:expensive-test)
   (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 620s
   (skip-unless (tramp--test-enabled))
   (skip-unless (tramp--test-sh-p))
   (skip-unless (not (tramp--test-docker-p)))
   (skip-unless (not (tramp--test-rsync-p)))
-  (skip-unless (not (tramp--test-windows-nt-and-out-of-band-p)))
+  (skip-unless (not (tramp--test-out-of-band-p))) ; SLOW
   (skip-unless (not (tramp--test-ksh-p)))
   (skip-unless (not (tramp--test-crypt-p)))
   ;; We cannot use `tramp-test-vec', because this fails during compilation.
@@ -6640,14 +6715,14 @@ Use the `perl' command."
 
 (ert-deftest tramp-test42-utf8-with-ls ()
   "Check UTF8 encoding in file names and file contents.
-Use the `ls' command."
+Use the \"ls\" command."
   :tags '(:expensive-test)
   (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 690s
   (skip-unless (tramp--test-enabled))
   (skip-unless (tramp--test-sh-p))
   (skip-unless (not (tramp--test-docker-p)))
   (skip-unless (not (tramp--test-rsync-p)))
-  (skip-unless (not (tramp--test-windows-nt-and-out-of-band-p)))
+  (skip-unless (not (tramp--test-out-of-band-p))) ; SLOW
   (skip-unless (not (tramp--test-ksh-p)))
   (skip-unless (not (tramp--test-crypt-p)))
 
@@ -6727,13 +6802,14 @@ process sentinels.  They shall not disturb each other."
   :tags (if (getenv "EMACS_EMBA_CI")
            '(:expensive-test :unstable) '(:expensive-test))
   (skip-unless (tramp--test-enabled))
+  (skip-unless (tramp--test-supports-processes-p))
   ;; Prior Emacs 27, `shell-file-name' was hard coded as "/bin/sh" for
   ;; remote processes in Emacs.  That doesn't work for tramp-adb.el.
-  (skip-unless (or (and (tramp--test-adb-p) (tramp--test-emacs27-p))
-                  (tramp--test-sh-p)))
-  (skip-unless (not (tramp--test-crypt-p)))
+  (when (tramp--test-adb-p)
+    (skip-unless (tramp--test-emacs27-p)))
   (skip-unless (not (tramp--test-docker-p)))
   (skip-unless (not (tramp--test-telnet-p)))
+  (skip-unless (not (tramp--test-sshfs-p)))
   (skip-unless (not (tramp--test-windows-nt-p)))
 
   (with-timeout
@@ -7221,8 +7297,8 @@ If INTERACTIVE is non-nil, the tests are run 
interactively."
 
 ;; * Work on skipped tests.  Make a comment, when it is impossible.
 ;; * Revisit expensive tests, once problems in `tramp-error' are solved.
-;; * Fix `tramp-test06-directory-file-name' for `ftp'.
-;; * Implement `tramp-test31-interrupt-process' for `adb', `sshfs' and
+;; * Fix `tramp-test06-directory-file-name' for "ftp".
+;; * Implement `tramp-test31-interrupt-process' for "adb", "sshfs" and
 ;;   for direct async processes.
 ;; * Check, why direct async processes do not work for
 ;;   `tramp-test44-asynchronous-requests'.
diff --git a/texi/tramp.texi b/texi/tramp.texi
index 4f786d9..c35fc51 100644
--- a/texi/tramp.texi
+++ b/texi/tramp.texi
@@ -290,7 +290,7 @@ file's contents.
 
 For external transfers, @value{tramp} sends a command as follows:
 @example
-rcp user@@host:/path/to/remote/file /tmp/tramp.4711
+$ rcp user@@host:/path/to/remote/file /tmp/tramp.4711
 @end example
 @value{tramp} reads the local temporary file @file{/tmp/tramp.4711}
 into a buffer, and then deletes the temporary file.
@@ -1071,7 +1071,7 @@ capable of servicing requests from @value{tramp}.
 
 This non-native @value{tramp} method connects via the Server Message
 Block (SMB) networking protocol to hosts running file servers that are
-typically based on @url{https://www.samba.org/,,Samba} or MS Windows.
+typically based on @uref{https://www.samba.org/,,Samba} or MS Windows.
 
 Using @command{smbclient} requires a few tweaks when working with
 @value{tramp}:
@@ -1323,7 +1323,7 @@ possible, @value{tramp} emulates those operations 
otherwise.
 
 @vindex tramp-rclone-program
 The program @command{rclone} allows to access different system
-storages in the cloud, see @url{https://rclone.org/} for a list of
+storages in the cloud, see @uref{https://rclone.org/} for a list of
 supported systems.  If the @command{rclone} program isn't found in
 your @env{PATH} environment variable, you can tell @value{tramp} its
 absolute path via the user option @code{tramp-rclone-program}.
@@ -1362,7 +1362,7 @@ for accessing the system storage, you should use it.
 On local hosts which have installed the @command{sshfs} client for
 mounting a file system based on @command{sftp}, this method can be
 used, see
-@url{https://github.com/libfuse/sshfs/blob/master/README.rst/}.  If
+@uref{https://github.com/libfuse/sshfs/blob/master/README.rst/}.  If
 the @command{sshfs} program isn't found in your @env{PATH} environment
 variable, you can tell @value{tramp} its absolute path via the user
 option @code{tramp-sshfs-program}.
@@ -2629,6 +2629,11 @@ Example:
 @end group
 @end lisp
 
+@vindex tramp-fuse-unmount-on-cleanup
+The user option @code{tramp-fuse-unmount-on-cleanup}, when set to
+non-@code{nil}, controls, whether a mount point is unmounted on
+connection cleanup or on Emacs exiting.
+
 
 @anchor{Setup of rclone method}
 @subsection @option{rclone} setup
@@ -4289,6 +4294,14 @@ passwords from @file{auth-source.el} (@pxref{Password 
handling}).  The
 latter does not happen for the @option{sudoedit} method, otherwise it
 would be unusable.
 
+If you use the GNU ELPA version of @value{tramp}, you must load it
+explicitly, because @command{emacs -Q} ignores installed ELPA
+packages.  Call (version number adapted)
+
+@example
+$ emacs -Q -l ~/.emacs.d/elpa/tramp-2.4.5.1/tramp-autoloads
+@end example
+
 When including @value{tramp}'s messages in the bug report, increase
 the verbosity level to 6 (@pxref{Traces and Profiles, Traces}) in the
 @file{~/.emacs} file before repeating steps to the bug.  Include the
@@ -4298,6 +4311,11 @@ non-@acronym{ASCII} characters which are relevant for 
analysis, append
 the buffers as attachments to the bug report.  This is also needed in
 order to avoid line breaks during mail transfer.
 
+If you send the message from Emacs, you are asked about to append
+these buffers to the bug report.  If you use an external mail program,
+you must save these buffers to files, and append them with that mail
+program.
+
 @strong{Note} that a verbosity level greater than 6 is not necessary
 at this stage.  Also note that a verbosity level of 6 or greater, the
 contents of files and directories will be included in the debug
@@ -5091,7 +5109,7 @@ location.
 Then start Emacs Client from the command line:
 
 @example
-emacsclient @trampfn{ssh,user@@host,/file/to/edit}
+$ emacsclient @trampfn{ssh,user@@host,/file/to/edit}
 @end example
 
 @code{user} and @code{host} refer to the local host.
@@ -5111,7 +5129,7 @@ Then change the environment variable @env{EDITOR} to 
point to the
 wrapper script:
 
 @example
-export EDITOR=/path/to/emacsclient.sh
+$ export EDITOR=/path/to/emacsclient.sh
 @end example
 
 
@@ -5174,12 +5192,15 @@ tramp-compat-with-mutex}
 
 @value{tramp} comes with compatibility code for different Emacs
 versions.  When you see such a message (the text might differ), you
-don't use the Emacs built-in version of @value{tramp}.  In case you
-have installed @value{tramp} from GNU ELPA, see the package README
-file for instructions how to recompile it.
+don't use the Emacs built-in version of @value{tramp}, and you must
+recompile it.  In case you have installed @value{tramp} from GNU ELPA,
 @ifset installchapter
-@xref{Recompilation}.
+@xref{ELPA Installation}.  Otherwise, @xref{Recompilation}.
 @end ifset
+@ifclear installchapter
+see @uref{@value{trampurl}#ELPA-Installation}.  Otherwise, see
+@uref{@value{trampurl}#Recompilation}.
+@end ifclear
 
 
 @item
@@ -5308,6 +5329,12 @@ handlers.
 
 @node External packages
 @section Integrating with external Lisp packages
+
+In general, it is not recommended to use @value{tramp} functions and
+variables not described in this manual.  They might change their
+signature and/or semantics without any announcement.
+
+
 @subsection File name completion
 
 @vindex non-essential
diff --git a/texi/trampver.texi b/texi/trampver.texi
index 9ce8330..fa83843 100644
--- a/texi/trampver.texi
+++ b/texi/trampver.texi
@@ -8,7 +8,7 @@
 @c In the Tramp GIT, the version numbers are auto-frobbed from
 @c tramp.el, and the bug report address is auto-frobbed from
 @c configure.ac.
-@set trampver 2.5.1.3
+@set trampver 2.5.1.4
 @set trampurl https://www.gnu.org/software/tramp/
 @set tramp-bug-report-address tramp-devel@@gnu.org
 @set emacsver 25.1
diff --git a/tramp-adb.el b/tramp-adb.el
index d68d4c7..362a258 100644
--- a/tramp-adb.el
+++ b/tramp-adb.el
@@ -128,8 +128,7 @@ It is used for TCP/IP devices."
     (file-attributes . tramp-adb-handle-file-attributes)
     (file-directory-p . tramp-handle-file-directory-p)
     (file-equal-p . tramp-handle-file-equal-p)
-    ;; FIXME: This is too sloppy.
-    (file-executable-p . tramp-handle-file-exists-p)
+    (file-executable-p . tramp-adb-handle-file-executable-p)
     (file-exists-p . tramp-handle-file-exists-p)
     (file-in-directory-p . tramp-handle-file-in-directory-p)
     (file-local-copy . tramp-adb-handle-file-local-copy)
@@ -147,7 +146,7 @@ It is used for TCP/IP devices."
     (file-notify-rm-watch . tramp-handle-file-notify-rm-watch)
     (file-notify-valid-p . tramp-handle-file-notify-valid-p)
     (file-ownership-preserved-p . ignore)
-    (file-readable-p . tramp-handle-file-exists-p)
+    (file-readable-p . tramp-adb-handle-file-readable-p)
     (file-regular-p . tramp-handle-file-regular-p)
     (file-remote-p . tramp-handle-file-remote-p)
     (file-selinux-context . tramp-handle-file-selinux-context)
@@ -515,28 +514,31 @@ Emacs dired can't find files."
        (set-file-modes tmpfile (logior (or (file-modes filename) 0) #o0400)))
       tmpfile)))
 
+(defun tramp-adb-handle-file-executable-p (filename)
+  "Like `file-executable-p' for Tramp files."
+  (with-parsed-tramp-file-name filename nil
+    (with-tramp-file-property v localname "file-executable-p"
+      (tramp-adb-send-command-and-check
+       v (format "test -x %s" (tramp-shell-quote-argument localname))))))
+
+(defun tramp-adb-handle-file-readable-p (filename)
+  "Like `file-readable-p' for Tramp files."
+  (with-parsed-tramp-file-name filename nil
+    (with-tramp-file-property v localname "file-readable-p"
+      (or (tramp-handle-file-readable-p filename)
+         (tramp-adb-send-command-and-check
+          v (format "test -r %s" (tramp-shell-quote-argument localname)))))))
+
 (defun tramp-adb-handle-file-writable-p (filename)
-  "Like `file-writable-p' for Tramp files.
-But handle the case, if the \"test\" command is not available."
+  "Like `file-writable-p' for Tramp files."
   (with-parsed-tramp-file-name filename nil
     (with-tramp-file-property v localname "file-writable-p"
-      (if (tramp-adb-find-test-command v)
-         (if (file-exists-p filename)
-             (tramp-adb-send-command-and-check
-              v (format "test -w %s" (tramp-shell-quote-argument localname)))
-           (and
-            (file-directory-p (file-name-directory filename))
-            (file-writable-p (file-name-directory filename))))
-
-       ;; Missing "test" command on Android < 4.
-       (let ((rw-path "/data/data"))
-        (tramp-message
-         v 5
-         "Not implemented yet (assuming \"/data/data\" is writable): %s"
-         localname)
-        (and (>= (length localname) (length rw-path))
-             (string= (substring localname 0 (length rw-path))
-                      rw-path)))))))
+      (if (file-exists-p filename)
+         (tramp-adb-send-command-and-check
+          v (format "test -w %s" (tramp-shell-quote-argument localname)))
+       (and
+        (file-directory-p (file-name-directory filename))
+        (file-writable-p (file-name-directory filename)))))))
 
 (defun tramp-adb-handle-write-region
   (start end filename &optional append visit lockname mustbenew)
@@ -600,7 +602,7 @@ But handle the case, if the \"test\" command is not 
available."
 
       ;; The end.
       (when (and (null noninteractive)
-                (or (eq visit t) (null visit) (stringp visit)))
+                (or (eq visit t) (string-or-null-p visit)))
        (tramp-message v 0 "Wrote %s" filename))
       (run-hooks 'tramp-handle-write-region-hook))))
 
@@ -933,8 +935,8 @@ implementation will be used."
              (stderr (plist-get args :stderr)))
          (unless (stringp name)
            (signal 'wrong-type-argument (list #'stringp name)))
-         (unless (or (null buffer) (bufferp buffer) (stringp buffer))
-           (signal 'wrong-type-argument (list #'stringp buffer)))
+         (unless (or (bufferp buffer) (string-or-null-p buffer))
+           (signal 'wrong-type-argument (list #'bufferp buffer)))
          (unless (consp command)
            (signal 'wrong-type-argument (list #'consp command)))
          (unless (or (null coding)
@@ -947,11 +949,11 @@ implementation will be used."
            (setq connection-type 'pty))
          (unless (memq connection-type '(nil pipe pty))
            (signal 'wrong-type-argument (list #'symbolp connection-type)))
-         (unless (or (null filter) (functionp filter))
+         (unless (or (null filter) (eq filter t) (functionp filter))
            (signal 'wrong-type-argument (list #'functionp filter)))
          (unless (or (null sentinel) (functionp sentinel))
            (signal 'wrong-type-argument (list #'functionp sentinel)))
-         (unless (or (null stderr) (bufferp stderr) (stringp stderr))
+         (unless (or (bufferp stderr) (string-or-null-p stderr))
            (signal 'wrong-type-argument (list #'bufferp stderr)))
          (when (and (stringp stderr) (tramp-tramp-file-p stderr)
                     (not (tramp-equal-remote default-directory stderr)))
@@ -1043,12 +1045,13 @@ implementation will be used."
                               (rename-file remote-tmpstderr stderr))))
                          ;; Read initial output.  Remove the first
                          ;; line, which is the command echo.
-                         (while
-                             (progn
-                               (goto-char (point-min))
-                               (not (re-search-forward "[\n]" nil t)))
-                           (tramp-accept-process-output p 0))
-                         (delete-region (point-min) (point))
+                         (unless (eq filter t)
+                           (while
+                               (progn
+                                 (goto-char (point-min))
+                                 (not (re-search-forward "[\n]" nil t)))
+                             (tramp-accept-process-output p 0))
+                           (delete-region (point-min) (point)))
                          ;; Provide error buffer.  This shows only
                          ;; initial error messages; messages arriving
                          ;; later on will be inserted when the
@@ -1141,12 +1144,6 @@ error and non-nil on success."
     (let ((inhibit-read-only t)) (delete-region (point-min) (point-max)))
     (zerop (apply #'tramp-call-process vec tramp-adb-program nil t nil args))))
 
-(defun tramp-adb-find-test-command (vec)
-  "Check whether the ash has a builtin \"test\" command.
-This happens for Android >= 4.0."
-  (with-tramp-connection-property vec "test"
-    (tramp-adb-send-command-and-check vec "type test")))
-
 ;; Connection functions
 
 (defun tramp-adb-send-command (vec command &optional neveropen nooutput)
diff --git a/tramp-archive.el b/tramp-archive.el
index b282359..8bf2515 100644
--- a/tramp-archive.el
+++ b/tramp-archive.el
@@ -353,6 +353,7 @@ arguments to pass to the OPERATION."
 ;;;###autoload
 (progn (defun tramp-archive-autoload-file-name-handler (operation &rest args)
   "Load Tramp archive file name handler, and perform OPERATION."
+  (defvar tramp-archive-autoload)
   (when tramp-archive-enabled
     ;; We cannot use `tramp-compat-temporary-file-directory' here due
     ;; to autoload.  When installing Tramp's GNU ELPA package, there
@@ -360,7 +361,6 @@ arguments to pass to the OPERATION."
     ;; overload this.
     (let ((default-directory temporary-file-directory)
           (tramp-archive-autoload t))
-      tramp-archive-autoload ; Silence byte compiler.
       (apply #'tramp-autoload-file-name-handler operation args)))))
 
 ;;;###autoload
diff --git a/tramp-cache.el b/tramp-cache.el
index 03cca2e..30408d3 100644
--- a/tramp-cache.el
+++ b/tramp-cache.el
@@ -319,12 +319,7 @@ KEY identifies the connection, it is either a process or a
 used to cache connection properties of the local machine.
 If KEY is `tramp-cache-undefined', or if the value is not set for
 the connection, return DEFAULT."
-  ;; Unify key by removing localname and hop from `tramp-file-name'
-  ;; structure.  Work with a copy in order to avoid side effects.
-  (when (tramp-file-name-p key)
-    (setq key (copy-tramp-file-name key))
-    (setf (tramp-file-name-localname key) nil
-         (tramp-file-name-hop key) nil))
+  (setq key (tramp-file-name-unify key))
   (let* ((hash (tramp-get-hash-table key))
         (cached (if (hash-table-p hash)
                     (gethash property hash tramp-cache-undefined)
@@ -350,12 +345,7 @@ used to cache connection properties of the local machine.  
If KEY
 is `tramp-cache-undefined', nothing is set.
 PROPERTY is set persistent when KEY is a `tramp-file-name' structure.
 Return VALUE."
-  ;; Unify key by removing localname and hop from `tramp-file-name'
-  ;; structure.  Work with a copy in order to avoid side effects.
-  (when (tramp-file-name-p key)
-    (setq key (copy-tramp-file-name key))
-    (setf (tramp-file-name-localname key) nil
-         (tramp-file-name-hop key) nil))
+  (setq key (tramp-file-name-unify key))
   (when-let ((hash (tramp-get-hash-table key)))
     (puthash property value hash))
   (setq tramp-cache-data-changed
@@ -379,12 +369,7 @@ KEY identifies the connection, it is either a process or a
 `tramp-file-name' structure.  A special case is nil, which is
 used to cache connection properties of the local machine.
 PROPERTY is set persistent when KEY is a `tramp-file-name' structure."
-  ;; Unify key by removing localname and hop from `tramp-file-name'
-  ;; structure.  Work with a copy in order to avoid side effects.
-  (when (tramp-file-name-p key)
-    (setq key (copy-tramp-file-name key))
-    (setf (tramp-file-name-localname key) nil
-         (tramp-file-name-hop key) nil))
+  (setq key (tramp-file-name-unify key))
   (when-let ((hash (tramp-get-hash-table key)))
     (remhash property hash))
   (setq tramp-cache-data-changed
@@ -397,12 +382,7 @@ PROPERTY is set persistent when KEY is a `tramp-file-name' 
structure."
 KEY identifies the connection, it is either a process or a
 `tramp-file-name' structure.  A special case is nil, which is
 used to cache connection properties of the local machine."
-  ;; Unify key by removing localname and hop from `tramp-file-name'
-  ;; structure.  Work with a copy in order to avoid side effects.
-  (when (tramp-file-name-p key)
-    (setq key (copy-tramp-file-name key))
-    (setf (tramp-file-name-localname key) nil
-         (tramp-file-name-hop key) nil))
+  (setq key (tramp-file-name-unify key))
   (tramp-message
    key 7 "%s %s" key
    (when-let ((hash (gethash key tramp-cache-data)))
diff --git a/tramp-fuse.el b/tramp-fuse.el
index 8c5afa7..c359082 100644
--- a/tramp-fuse.el
+++ b/tramp-fuse.el
@@ -156,34 +156,56 @@
        (tramp-file-name-host-port vec))
        tramp-compat-temporary-file-directory)))
 
+(defconst tramp-fuse-mount-timeout
+  (eval (car (get 'remote-file-name-inhibit-cache 'standard-value)) t)
+  "Time period to check whether the mount point still exists.
+It has the same meaning as `remote-file-name-inhibit-cache'.")
+
 (defun tramp-fuse-mounted-p (vec)
   "Check, whether fuse volume determined by VEC is mounted."
-  (when (tramp-get-connection-process vec)
-    ;; We cannot use `with-connection-property', because we don't want
-    ;; to cache a nil result.
-    (or (tramp-get-connection-property
-         (tramp-get-connection-process vec) "mounted" nil)
+  ;; Remember the mount status by using a file property on "/",
+  ;; instead of using a connection property, because a file property
+  ;; has a timeout.  Having a timeout lets us regularly recheck the
+  ;; mount status, as requested by `tramp-fuse-mount-timeout'.  We
+  ;; cannot use `with-tramp-file-property', because we don't want to
+  ;; cache a nil result.
+  (let ((remote-file-name-inhibit-cache tramp-fuse-mount-timeout))
+    (or (tramp-get-file-property vec "/" "mounted" nil)
         (let* ((default-directory tramp-compat-temporary-file-directory)
                (command (format "mount -t fuse.%s" (tramp-file-name-method 
vec)))
               (mount (shell-command-to-string command)))
           (tramp-message vec 6 "%s\n%s" command mount)
-          (tramp-set-connection-property
-           (tramp-get-connection-process vec) "mounted"
+          (tramp-set-file-property
+          vec "/" "mounted"
            (when (string-match
                  (format
                    "^\\(%s\\)\\s-" (regexp-quote (tramp-fuse-mount-spec vec)))
                  mount)
              (match-string 1 mount)))))))
 
+(defun tramp-fuse-get-fusermount ()
+  "Determine the local `fusermount' command."
+  ;; We use key nil for local connection properties.
+  (with-tramp-connection-property nil "fusermount"
+    (or (executable-find "fusermount3")
+       (executable-find "fusermount"))))
+
+(defvar tramp-fuse-mount-points nil
+  "List of fuse volume determined by a VEC.")
+
 (defun tramp-fuse-unmount (vec)
   "Unmount fuse volume determined by VEC."
-  (let ((default-directory tramp-compat-temporary-file-directory)
-        (command (format "fusermount3 -u %s" (tramp-fuse-mount-point vec))))
+  (let* ((default-directory tramp-compat-temporary-file-directory)
+        (mount-point (tramp-fuse-mount-point vec))
+         (command (format "%s -u %s" (tramp-fuse-get-fusermount) mount-point)))
     (tramp-message vec 6 "%s\n%s" command (shell-command-to-string command))
-    (tramp-flush-connection-property
-     (tramp-get-connection-process vec) "mounted")
+    (tramp-flush-file-property vec "/" "mounted")
+    (setq tramp-fuse-mount-points
+         (delete (tramp-file-name-unify vec) tramp-fuse-mount-points))
     ;; Give the caches a chance to expire.
-    (sleep-for 1)))
+    (sleep-for 1)
+    (when (tramp-compat-directory-empty-p mount-point)
+      (delete-directory mount-point))))
 
 (defun tramp-fuse-local-file-name (filename)
   "Return local mount name of FILENAME."
@@ -205,6 +227,36 @@
              (substring localname 1) localname)
          (tramp-fuse-mount-point v)))))))
 
+(defcustom tramp-fuse-unmount-on-cleanup nil
+  "Whether fuse volumes shall be unmounted on cleanup."
+  :group 'tramp
+  :version "28.1"
+  :type 'boolean)
+
+(defun tramp-fuse-cleanup (vec)
+  "Cleanup fuse volume determined by VEC."
+  (and tramp-fuse-unmount-on-cleanup
+       (member (tramp-file-name-unify vec) tramp-fuse-mount-points)
+       (tramp-fuse-unmount vec)))
+
+(defun tramp-fuse-cleanup-all ()
+  "Unmount all fuse volumes used by Tramp."
+  (and tramp-fuse-unmount-on-cleanup
+       (mapc #'tramp-fuse-unmount tramp-fuse-mount-points)))
+
+;; Add cleanup hooks.
+(add-hook 'tramp-cleanup-connection-hook #'tramp-fuse-cleanup)
+(add-hook 'tramp-cleanup-all-connections-hook #'tramp-fuse-cleanup-all)
+(add-hook 'kill-emacs-hook #'tramp-fuse-cleanup-all)
+(add-hook 'tramp-fuse-unload-hook
+         (lambda ()
+           (remove-hook 'tramp-cleanup-connection-hook
+                        #'tramp-fuse-cleanup)
+           (remove-hook 'tramp-cleanup-all-connections-hook
+                        #'tramp-fuse-cleanup-all)
+           (remove-hook 'kill-emacs-hook
+                        #'tramp-fuse-cleanup-all)))
+
 (add-hook 'tramp-unload-hook
          (lambda ()
            (unload-feature 'tramp-fuse 'force)))
diff --git a/tramp-gvfs.el b/tramp-gvfs.el
index 115d005..7e22639 100644
--- a/tramp-gvfs.el
+++ b/tramp-gvfs.el
@@ -788,7 +788,7 @@ It has been changed in GVFS 1.14.")
     (file-notify-rm-watch . tramp-handle-file-notify-rm-watch)
     (file-notify-valid-p . tramp-handle-file-notify-valid-p)
     (file-ownership-preserved-p . ignore)
-    (file-readable-p . tramp-gvfs-handle-file-readable-p)
+    (file-readable-p . tramp-handle-file-readable-p)
     (file-regular-p . tramp-handle-file-regular-p)
     (file-remote-p . tramp-handle-file-remote-p)
     (file-selinux-context . tramp-handle-file-selinux-context)
@@ -1396,8 +1396,7 @@ If FILE-SYSTEM is non-nil, return file system attributes."
   "Like `file-executable-p' for Tramp files."
   (with-parsed-tramp-file-name filename nil
     (with-tramp-file-property v localname "file-executable-p"
-      (and (file-exists-p filename)
-          (tramp-check-cached-permissions v ?x)))))
+      (tramp-check-cached-permissions v ?x))))
 
 (defun tramp-gvfs-handle-file-name-all-completions (filename directory)
   "Like `file-name-all-completions' for Tramp files."
@@ -1519,31 +1518,6 @@ If FILE-SYSTEM is non-nil, return file system 
attributes."
     (when string (tramp-message proc 10 "Rest string:\n%s" string))
     (process-put proc 'rest-string string)))
 
-(defun tramp-gvfs-handle-file-readable-p (filename)
-  "Like `file-readable-p' for Tramp files."
-  (with-parsed-tramp-file-name filename nil
-    (with-tramp-file-property v localname "file-readable-p"
-      (and (file-exists-p filename)
-          (or (tramp-check-cached-permissions v ?r)
-              ;; `tramp-check-cached-permissions' doesn't handle
-              ;; symbolic links.
-              (and (stringp (file-symlink-p filename))
-                   (file-readable-p
-                    (concat
-                     (file-remote-p filename) (file-symlink-p filename))))
-              ;; If the user is different from what we guess to be
-              ;; the user, we don't know.  Let's check, whether
-              ;; access is restricted explicitly.
-              (and (/= (tramp-get-remote-uid v 'integer)
-                       (tramp-compat-file-attribute-user-id
-                        (file-attributes filename 'integer)))
-                   (not
-                    (string-equal
-                     "FALSE"
-                     (cdr (assoc
-                           "access::can-read"
-                           (tramp-gvfs-get-file-attributes filename)))))))))))
-
 (defun tramp-gvfs-handle-file-system-info (filename)
   "Like `file-system-info' for Tramp files."
   (setq filename (directory-file-name (expand-file-name filename)))
@@ -1892,7 +1866,11 @@ Their full names are 
\"org.gtk.vfs.MountTracker.mounted\" and
                    port (tramp-file-name-port v)))))
        (when (member method tramp-gvfs-methods)
          (with-parsed-tramp-file-name
-             (tramp-make-tramp-file-name method user domain host port "") nil
+             ;; This must be changed when we throw the old signature
+             ;; away in Emacs 27.1 and higher.
+             (with-no-warnings
+               (tramp-make-tramp-file-name method user domain host port ""))
+             nil
            (tramp-message
             v 6 "%s %s"
             signal-name (tramp-gvfs-stringify-dbus-message mount-info))
diff --git a/tramp-rclone.el b/tramp-rclone.el
index 49e366c..812e06f 100644
--- a/tramp-rclone.el
+++ b/tramp-rclone.el
@@ -386,6 +386,7 @@ connection if a previous connection has died for some 
reason."
          (tramp-cleanup-connection vec 'keep-debug 'keep-password))
 
        ;; Mark it as connected.
+       (add-to-list 'tramp-fuse-mount-points (tramp-file-name-unify vec))
        (tramp-set-connection-property
         (tramp-get-connection-process vec) "connected" t))))
 
diff --git a/tramp-sh.el b/tramp-sh.el
index dd92f22..6f3b324 100644
--- a/tramp-sh.el
+++ b/tramp-sh.el
@@ -1580,9 +1580,7 @@ ID-FORMAT valid values are `string' and `integer'."
   "Like `file-readable-p' for Tramp files."
   (with-parsed-tramp-file-name filename nil
     (with-tramp-file-property v localname "file-readable-p"
-      ;; Examine `file-attributes' cache to see if request can be
-      ;; satisfied without remote operation.
-      (or (tramp-check-cached-permissions v ?r)
+      (or (tramp-handle-file-readable-p filename)
          (tramp-run-test "-r" filename)))))
 
 ;; Functions implemented using the basic functions above.
@@ -2771,8 +2769,8 @@ implementation will be used."
              (stderr (plist-get args :stderr)))
          (unless (stringp name)
            (signal 'wrong-type-argument (list #'stringp name)))
-         (unless (or (null buffer) (bufferp buffer) (stringp buffer))
-           (signal 'wrong-type-argument (list #'stringp buffer)))
+         (unless (or (bufferp buffer) (string-or-null-p buffer))
+           (signal 'wrong-type-argument (list #'bufferp buffer)))
          (unless (or (null command) (consp command))
            (signal 'wrong-type-argument (list #'consp command)))
          (unless (or (null coding)
@@ -2785,11 +2783,11 @@ implementation will be used."
            (setq connection-type 'pty))
          (unless (memq connection-type '(nil pipe pty))
            (signal 'wrong-type-argument (list #'symbolp connection-type)))
-         (unless (or (null filter) (functionp filter))
+         (unless (or (null filter) (eq filter t) (functionp filter))
            (signal 'wrong-type-argument (list #'functionp filter)))
          (unless (or (null sentinel) (functionp sentinel))
            (signal 'wrong-type-argument (list #'functionp sentinel)))
-         (unless (or (null stderr) (bufferp stderr) (stringp stderr))
+         (unless (or (bufferp stderr) (string-or-null-p stderr))
            (signal 'wrong-type-argument (list #'bufferp stderr)))
          (when (and (stringp stderr)
                     (not (tramp-equal-remote default-directory stderr)))
@@ -3513,7 +3511,7 @@ implementation will be used."
          (tramp-compat-funcall 'unlock-file lockname))
 
        (when (and (null noninteractive)
-                  (or (eq visit t) (null visit) (stringp visit)))
+                  (or (eq visit t) (string-or-null-p visit)))
          (tramp-message v 0 "Wrote %s" filename))
        (run-hooks 'tramp-handle-write-region-hook)))))
 
diff --git a/tramp-smb.el b/tramp-smb.el
index 87f3665..49f049d 100644
--- a/tramp-smb.el
+++ b/tramp-smb.el
@@ -1658,7 +1658,7 @@ errors for shares like \"C$/\", which are common in 
Microsoft Windows."
 
       ;; The end.
       (when (and (null noninteractive)
-                (or (eq visit t) (null visit) (stringp visit)))
+                (or (eq visit t) (string-or-null-p visit)))
        (tramp-message v 0 "Wrote %s" filename))
       (run-hooks 'tramp-handle-write-region-hook))))
 
diff --git a/tramp-sshfs.el b/tramp-sshfs.el
index 0019ac0..a100786 100644
--- a/tramp-sshfs.el
+++ b/tramp-sshfs.el
@@ -222,11 +222,14 @@ arguments to pass to the OPERATION."
 (defun tramp-sshfs-handle-insert-file-contents
   (filename &optional visit beg end replace)
   "Like `insert-file-contents' for Tramp files."
-  (let ((result
-        (insert-file-contents
-         (tramp-fuse-local-file-name filename) visit beg end replace)))
-    (when visit (setq buffer-file-name filename))
-    (cons (expand-file-name filename) (cdr result))))
+  (setq filename (expand-file-name filename))
+  (let (signal-hook-function result)
+    (unwind-protect
+        (setq result
+             (insert-file-contents
+              (tramp-fuse-local-file-name filename) visit beg end replace))
+      (when visit (setq buffer-file-name filename))
+      (cons filename (cdr result)))))
 
 (defun tramp-sshfs-handle-process-file
   (program &optional infile destination display &rest args)
@@ -317,7 +320,7 @@ arguments to pass to the OPERATION."
 
       ;; The end.
       (when (and (null noninteractive)
-                (or (eq visit t) (null visit) (stringp visit)))
+                (or (eq visit t) (string-or-null-p visit)))
        (tramp-message v 0 "Wrote %s" filename))
       (run-hooks 'tramp-handle-write-region-hook))))
 
@@ -346,30 +349,31 @@ connection if a previous connection has died for some 
reason."
       (tramp-set-connection-property p "lock-pid" (truncate (time-to-seconds)))
 
       ;; Set connection-local variables.
-      (tramp-set-connection-local-variables vec)
-
-      ;; Create directory.
-      (unless (file-directory-p (tramp-fuse-mount-point vec))
-       (make-directory (tramp-fuse-mount-point vec) 'parents))
-
-      (unless
-         (or (tramp-fuse-mounted-p vec)
-             (with-temp-buffer
-               (zerop
-                (apply
-                 #'tramp-call-process
-                 vec tramp-sshfs-program nil t nil
-                 (tramp-fuse-mount-spec vec)
-                 (tramp-fuse-mount-point vec)
-                 (tramp-expand-args
-                  vec 'tramp-mount-args
-                  ?p (or (tramp-file-name-port vec) "")))))
-         (tramp-error
-          vec 'file-error "Error mounting %s" (tramp-fuse-mount-spec vec))))
-
-      ;; Mark it as connected.
-      (tramp-set-connection-property
-       (tramp-get-connection-process vec) "connected" t)))
+      (tramp-set-connection-local-variables vec)))
+
+  ;; Create directory.
+  (unless (file-directory-p (tramp-fuse-mount-point vec))
+    (make-directory (tramp-fuse-mount-point vec) 'parents))
+
+  (unless
+      (or (tramp-fuse-mounted-p vec)
+         (with-temp-buffer
+           (zerop
+            (apply
+             #'tramp-call-process
+             vec tramp-sshfs-program nil t nil
+             (tramp-fuse-mount-spec vec)
+             (tramp-fuse-mount-point vec)
+             (tramp-expand-args
+              vec 'tramp-mount-args
+              ?p (or (tramp-file-name-port vec) ""))))))
+    (tramp-error
+     vec 'file-error "Error mounting %s" (tramp-fuse-mount-spec vec)))
+
+  ;; Mark it as connected.
+  (add-to-list 'tramp-fuse-mount-points (tramp-file-name-unify vec))
+  (tramp-set-connection-property
+   (tramp-get-connection-process vec) "connected" t)
 
   ;; In `tramp-check-cached-permissions', the connection properties
   ;; "{uid,gid}-{integer,string}" are used.  We set them to proper values.
diff --git a/tramp-sudoedit.el b/tramp-sudoedit.el
index 516d46d..845f31d 100644
--- a/tramp-sudoedit.el
+++ b/tramp-sudoedit.el
@@ -464,8 +464,9 @@ the result will be a local, non-Tramp, file name."
   "Like `file-readable-p' for Tramp files."
   (with-parsed-tramp-file-name filename nil
     (with-tramp-file-property v localname "file-readable-p"
-      (tramp-sudoedit-send-command
-       v "test" "-r" (tramp-compat-file-name-unquote localname)))))
+      (or (tramp-handle-file-readable-p filename)
+         (tramp-sudoedit-send-command
+          v "test" "-r" (tramp-compat-file-name-unquote localname))))))
 
 (defun tramp-sudoedit-handle-set-file-modes (filename mode &optional flag)
   "Like `set-file-modes' for Tramp files."
diff --git a/tramp.el b/tramp.el
index c883935..f2ae200 100644
--- a/tramp.el
+++ b/tramp.el
@@ -1304,7 +1304,7 @@ let-bind this variable."
 ;; "getconf PATH" yields:
 ;; HP-UX: 
/usr/bin:/usr/ccs/bin:/opt/ansic/bin:/opt/langtools/bin:/opt/fortran/bin
 ;; Solaris: /usr/xpg4/bin:/usr/ccs/bin:/usr/bin:/opt/SUNWspro/bin
-;; GNU/Linux (Debian, Suse, RHEL): /bin:/usr/bin
+;; GNU/Linux (Debian, Suse, RHEL, Cygwin, MINGW64): /bin:/usr/bin
 ;; FreeBSD, DragonFly: /usr/bin:/bin:/usr/sbin:/sbin: - beware trailing ":"!
 ;; FreeBSD 12.1, Darwin: /usr/bin:/bin:/usr/sbin:/sbin
 ;; IRIX64: /usr/bin
@@ -1326,9 +1326,9 @@ tilde expansion, all directory names starting with \"~\" 
will be ignored.
 the command \"getconf PATH\".  It is recommended to use this
 entry on head of this list, because these are the default
 directories for POSIX compatible commands.  On remote hosts which
-do not offer the getconf command (like cygwin), the value
-\"/bin:/usr/bin\" is used instead.  This entry is represented in
-the list by the special value `tramp-default-remote-path'.
+do not offer the getconf command, the value \"/bin:/usr/bin\" is
+used instead.  This entry is represented in the list by the
+special value `tramp-default-remote-path'.
 
 `Private Directories' are the settings of the $PATH environment,
 as given in your `~/.profile'.  This entry is represented in
@@ -1450,16 +1450,24 @@ If nil, return `tramp-default-port'."
 
 (put #'tramp-file-name-port-or-default 'tramp-suppress-trace t)
 
+(defun tramp-file-name-unify (vec)
+  "Unify VEC by removing localname and hop from `tramp-file-name' structure.
+Objects returned by this function compare `equal' if they refer to the
+same connection.  Make a copy in order to avoid side effects."
+  (when (tramp-file-name-p vec)
+    (setq vec (copy-tramp-file-name vec))
+    (setf (tramp-file-name-localname vec) nil
+         (tramp-file-name-hop vec) nil))
+  vec)
+
+(put #'tramp-file-name-unify 'tramp-suppress-trace t)
+
 ;; Comparison of file names is performed by `tramp-equal-remote'.
 (defun tramp-file-name-equal-p (vec1 vec2)
   "Check, whether VEC1 and VEC2 denote the same `tramp-file-name'."
   (and (tramp-file-name-p vec1) (tramp-file-name-p vec2)
-       (string-equal (tramp-file-name-method vec1)
-                    (tramp-file-name-method vec2))
-       (string-equal (tramp-file-name-user-domain vec1)
-                    (tramp-file-name-user-domain vec2))
-       (string-equal (tramp-file-name-host-port vec1)
-                    (tramp-file-name-host-port vec2))))
+       (equal (tramp-file-name-unify vec1)
+             (tramp-file-name-unify vec2))))
 
 (defun tramp-get-method-parameter (vec param)
   "Return the method parameter PARAM.
@@ -1750,6 +1758,9 @@ the form (METHOD USER DOMAIN HOST PORT LOCALNAME 
&optional HOP)."
            tramp-postfix-host-format
            localname)))
 
+(set-advertised-calling-convention
+ #'tramp-make-tramp-file-name '(vec &optional localname hop) "27.1")
+
 (defun tramp-make-tramp-hop-name (vec)
   "Construct a Tramp hop name from VEC."
   (replace-regexp-in-string
@@ -2083,8 +2094,7 @@ VEC-OR-PROC identifies the connection to use, SIGNAL is 
the
 signal identifier to be raised, remaining arguments passed to
 `tramp-message'.  Finally, signal SIGNAL is raised with
 FMT-STRING and ARGUMENTS."
-  (let ((inhibit-message t)
-       signal-hook-function)
+  (let (signal-hook-function)
     (tramp-backtrace vec-or-proc)
     (unless arguments
       ;; FMT-STRING could be just a file name, as in
@@ -2194,9 +2204,10 @@ the resulting error message."
   ;; `custom-initialize-*' functions provoke `void-variable' errors.
   ;; We don't want to see them in the backtrace.
   (unless (eq error-symbol 'void-variable)
-    (tramp-error
-     (car tramp-current-connection) error-symbol
-     (mapconcat (lambda (x) (format "%s" x)) data " "))))
+    (let ((inhibit-message t))
+      (tramp-error
+       (car tramp-current-connection) error-symbol
+       (mapconcat (lambda (x) (format "%s" x)) data " ")))))
 
 (put #'tramp-signal-hook-function 'tramp-suppress-trace t)
 
@@ -3301,10 +3312,18 @@ User is always nil."
 
 (defun tramp-handle-access-file (filename string)
   "Like `access-file' for Tramp files."
-  (unless (file-readable-p (file-truename filename))
-    (tramp-compat-file-missing
-     (tramp-dissect-file-name filename)
-     (format "%s: %s" string filename))))
+  (setq filename (file-truename filename))
+  (with-parsed-tramp-file-name filename v
+    (if (file-exists-p filename)
+       (unless
+           (funcall
+            (if (file-directory-p filename)
+                #'file-accessible-directory-p #'file-readable-p)
+            filename)
+         (tramp-error
+          v 'file-error (format "%s: Permission denied, %s" string filename)))
+      (tramp-compat-file-missing
+       v (format "%s: No such file or directory, %s" string filename)))))
 
 (defun tramp-handle-add-name-to-file
   (filename newname &optional ok-if-already-exists)
@@ -3594,6 +3613,17 @@ User is always nil."
        (tramp-compat-file-attribute-modification-time
        (file-attributes file1))))))
 
+(defun tramp-handle-file-readable-p (filename)
+  "Like `file-readable-p' for Tramp files."
+  (with-parsed-tramp-file-name filename nil
+    (with-tramp-file-property v localname "file-readable-p"
+      (or (tramp-check-cached-permissions v ?r)
+         ;; `tramp-check-cached-permissions' doesn't handle symbolic
+         ;; links.
+         (when-let ((symlink (file-symlink-p filename)))
+           (and (stringp symlink)
+                (file-readable-p (concat (file-remote-p filename) 
symlink))))))))
+
 (defun tramp-handle-file-regular-p (filename)
   "Like `file-regular-p' for Tramp files."
   (and (file-exists-p filename)
@@ -3777,7 +3807,8 @@ User is always nil."
     (with-parsed-tramp-file-name filename nil
       (unwind-protect
          (if (not (file-exists-p filename))
-             (tramp-compat-file-missing v filename)
+              (let ((tramp-verbose (if visit 0 tramp-verbose)))
+               (tramp-compat-file-missing v filename))
 
            (with-tramp-progress-reporter
                v 3 (format-message "Inserting `%s'" filename)
@@ -3879,7 +3910,7 @@ User is always nil."
          (delete-file (tramp-make-tramp-file-name v remote-copy 'nohop))))
 
       ;; Result.
-      (cons (expand-file-name filename) (cdr result)))))
+      (cons filename (cdr result)))))
 
 (defun tramp-get-lock-file (file)
   "Read lockfile info of FILE.
@@ -3954,7 +3985,8 @@ Return nil when there is no lockfile."
            (tramp-error v 'file-error "Unsafe lock file name")))
 
        ;; Do the lock.
-        (let (create-lockfiles signal-hook-function)
+        (let ((tramp-verbose 0)
+              create-lockfiles signal-hook-function)
          (condition-case nil
              (make-symbolic-link info lockname 'ok-if-already-exists)
            (error
@@ -4151,8 +4183,8 @@ substitution.  SPEC-LIST is a list of char/value pairs 
used for
            (stderr (plist-get args :stderr)))
        (unless (stringp name)
          (signal 'wrong-type-argument (list #'stringp name)))
-       (unless (or (null buffer) (bufferp buffer) (stringp buffer))
-         (signal 'wrong-type-argument (list #'stringp buffer)))
+       (unless (or (bufferp buffer) (string-or-null-p buffer))
+         (signal 'wrong-type-argument (list #'bufferp buffer)))
        (unless (consp command)
          (signal 'wrong-type-argument (list #'consp command)))
        (unless (or (null coding)
@@ -4165,7 +4197,7 @@ substitution.  SPEC-LIST is a list of char/value pairs 
used for
          (setq connection-type 'pty))
        (unless (memq connection-type '(nil pipe pty))
          (signal 'wrong-type-argument (list #'symbolp connection-type)))
-       (unless (or (null filter) (functionp filter))
+       (unless (or (null filter) (eq filter t) (functionp filter))
          (signal 'wrong-type-argument (list #'functionp filter)))
        (unless (or (null sentinel) (functionp sentinel))
          (signal 'wrong-type-argument (list #'functionp sentinel)))
@@ -4244,7 +4276,12 @@ substitution.  SPEC-LIST is a list of char/value pairs 
used for
                :name name :buffer buffer
                :command (append `(,login-program) login-args command)
                :coding coding :noquery noquery :connection-type connection-type
-               :filter filter :sentinel sentinel :stderr stderr))
+               :sentinel sentinel :stderr stderr))
+           ;; Set filter.  Prior Emacs 29.1, it doesn't work reliable
+           ;; to provide it as `make-process' argument when filter is
+           ;; t.  See Bug#51177.
+           (when filter
+             (set-process-filter p filter))
 
            (tramp-message v 6 "%s" (string-join (process-command p) " "))
            p))))))
@@ -4588,7 +4625,7 @@ of."
 
       ;; The end.
       (when (and (null noninteractive)
-                (or (eq visit t) (null visit) (stringp visit)))
+                (or (eq visit t) (string-or-null-p visit)))
        (tramp-message v 0 "Wrote %s" filename))
       (run-hooks 'tramp-handle-write-region-hook))))
 
@@ -4654,9 +4691,8 @@ of."
   (let ((user (or (tramp-file-name-user vec)
                  (with-tramp-connection-property vec "login-as"
                    (save-window-excursion
-                     (let ((enable-recursive-minibuffers t))
-                       (pop-to-buffer (tramp-get-connection-buffer vec))
-                       (read-string (match-string 0))))))))
+                     (pop-to-buffer (tramp-get-connection-buffer vec))
+                     (read-string (match-string 0)))))))
     (with-current-buffer (tramp-get-connection-buffer vec)
       (tramp-message vec 6 "\n%s" (buffer-string)))
     (tramp-message vec 3 "Sending login name `%s'" user)
@@ -4666,8 +4702,7 @@ of."
 (defun tramp-action-password (proc vec)
   "Query the user for a password."
   (with-current-buffer (process-buffer proc)
-    (let ((enable-recursive-minibuffers t)
-         (case-fold-search t))
+    (let ((case-fold-search t))
       ;; Let's check whether a wrong password has been sent already.
       ;; Sometimes, the process returns a new password request
       ;; immediately after rejecting the previous (wrong) one.
@@ -4698,14 +4733,13 @@ of."
 Send \"yes\" to remote process on confirmation, abort otherwise.
 See also `tramp-action-yn'."
   (save-window-excursion
-    (let ((enable-recursive-minibuffers t))
-      (pop-to-buffer (tramp-get-connection-buffer vec))
-      (unless (yes-or-no-p (match-string 0))
-       (kill-process proc)
-       (throw 'tramp-action 'permission-denied))
-      (with-current-buffer (tramp-get-connection-buffer vec)
-       (tramp-message vec 6 "\n%s" (buffer-string)))
-      (tramp-send-string vec (concat "yes" tramp-local-end-of-line))))
+    (pop-to-buffer (tramp-get-connection-buffer vec))
+    (unless (yes-or-no-p (match-string 0))
+      (kill-process proc)
+      (throw 'tramp-action 'permission-denied))
+    (with-current-buffer (tramp-get-connection-buffer vec)
+      (tramp-message vec 6 "\n%s" (buffer-string)))
+    (tramp-send-string vec (concat "yes" tramp-local-end-of-line)))
   t)
 
 (defun tramp-action-yn (proc vec)
@@ -4713,14 +4747,13 @@ See also `tramp-action-yn'."
 Send \"y\" to remote process on confirmation, abort otherwise.
 See also `tramp-action-yesno'."
   (save-window-excursion
-    (let ((enable-recursive-minibuffers t))
-      (pop-to-buffer (tramp-get-connection-buffer vec))
-      (unless (y-or-n-p (match-string 0))
-       (kill-process proc)
-       (throw 'tramp-action 'permission-denied))
-      (with-current-buffer (tramp-get-connection-buffer vec)
-       (tramp-message vec 6 "\n%s" (buffer-string)))
-      (tramp-send-string vec (concat "y" tramp-local-end-of-line))))
+    (pop-to-buffer (tramp-get-connection-buffer vec))
+    (unless (y-or-n-p (match-string 0))
+      (kill-process proc)
+      (throw 'tramp-action 'permission-denied))
+    (with-current-buffer (tramp-get-connection-buffer vec)
+      (tramp-message vec 6 "\n%s" (buffer-string)))
+    (tramp-send-string vec (concat "y" tramp-local-end-of-line)))
   t)
 
 (defun tramp-action-terminal (_proc vec)
@@ -4854,7 +4887,8 @@ performed successfully.  Any other value means an error."
   (save-restriction
     (with-tramp-progress-reporter
        proc 3 "Waiting for prompts from remote shell"
-      (let (exit)
+      (let ((enable-recursive-minibuffers t)
+           exit)
        (if timeout
            (with-timeout (timeout (setq exit 'timeout))
              (while (not exit)
diff --git a/trampver.el b/trampver.el
index 299a49b..89499b5 100644
--- a/trampver.el
+++ b/trampver.el
@@ -7,7 +7,7 @@
 ;; Maintainer: Michael Albinus <michael.albinus@gmx.de>
 ;; Keywords: comm, processes
 ;; Package: tramp
-;; Version: 2.5.1.3
+;; Version: 2.5.1.4
 ;; Package-Requires: ((emacs "25.1"))
 ;; Package-Type: multi
 ;; URL: https://www.gnu.org/software/tramp/
@@ -40,7 +40,7 @@
 ;; ./configure" to change them.
 
 ;;;###tramp-autoload
-(defconst tramp-version "2.5.1.3"
+(defconst tramp-version "2.5.1.4"
   "This version of Tramp.")
 
 ;;;###tramp-autoload
@@ -76,7 +76,7 @@
 ;; Check for Emacs version.
 (let ((x   (if (not (string-lessp emacs-version "25.1"))
       "ok"
-    (format "Tramp 2.5.1.3 is not fit for %s"
+    (format "Tramp 2.5.1.4 is not fit for %s"
             (replace-regexp-in-string "\n" "" (emacs-version))))))
   (unless (string-equal "ok" x) (error "%s" x)))
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]