diff options
Diffstat (limited to 'lisp/net/tramp.el')
-rw-r--r-- | lisp/net/tramp.el | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 6eff5b2ca60..3420bb76d14 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -1722,11 +1722,11 @@ default values are used." (unless (or nodefault non-essential (assoc method tramp-methods)) (tramp-user-error - v "Method `%s' is not known." method)) + v "Method `%s' is not known" method)) ;; Only some methods from tramp-sh.el do support multi-hops. (unless (or (null hop) nodefault non-essential (tramp-multi-hop-p v)) (tramp-user-error - v "Method `%s' is not supported for multi-hops." method))))))) + v "Method `%s' is not supported for multi-hops" method))))))) (put #'tramp-dissect-file-name 'tramp-suppress-trace t) @@ -1755,7 +1755,7 @@ See `tramp-dissect-file-name' for details." ;; Only some methods from tramp-sh.el do support multi-hops. (unless (or nodefault non-essential (tramp-multi-hop-p v)) (tramp-user-error - v "Method `%s' is not supported for multi-hops." + v "Method `%s' is not supported for multi-hops" (tramp-file-name-method v))) ;; Return result. v)) @@ -3936,7 +3936,7 @@ Let-bind it when necessary.") ;; Some handlers for `tramp-get-remote-uid' return nil if they ;; can't get the UID; always return -1 in this case for ;; consistency. - -1))) + tramp-unknown-id-integer))) (defun tramp-handle-access-file (filename string) "Like `access-file' for Tramp files." @@ -4791,10 +4791,12 @@ Do not set it manually, it is used buffer-local in `tramp-get-lock-pid'.") (delete-file lockname) ;; Trigger the unlock error. (signal 'file-error `("Cannot remove lock file for" ,file))) - ;; `userlock--handle-unlock-error' exists since Emacs 28.1. - (error - (when create-lockfiles - (tramp-compat-funcall 'userlock--handle-unlock-error err))))) + ;; `userlock--handle-unlock-error' exists since Emacs 28.1. It + ;; checks for `create-lockfiles' since Emacs 30.1, we don't need + ;; this check here, then. + (error (unless (or (not create-lockfiles) + (bound-and-true-p remote-file-name-inhibit-locks)) + (tramp-compat-funcall 'userlock--handle-unlock-error err))))) (defun tramp-handle-load (file &optional noerror nomessage nosuffix must-suffix) "Like `load' for Tramp files." @@ -4896,7 +4898,7 @@ Do not set it manually, it is used buffer-local in `tramp-get-lock-pid'.") (unless (tramp-multi-hop-p item) (setq tramp-default-proxies-alist saved-tdpa) (tramp-user-error - vec "Method `%s' is not supported for multi-hops." + vec "Method `%s' is not supported for multi-hops" (tramp-file-name-method item))))) ;; Some methods ("su", "sg", "sudo", "doas", "ksu") do not use the @@ -5815,7 +5817,7 @@ If the user quits via `C-g', it is propagated up to `tramp-file-name-handler'." (v (process-get proc 'tramp-vector))) (dolist (p (delq proc (process-list))) (when (tramp-file-name-equal-p v (process-get p 'tramp-vector)) - (accept-process-output p 0 nil t)))) + (with-local-quit (accept-process-output p 0 nil t))))) (with-current-buffer (process-buffer proc) (let ((inhibit-read-only t) |