From: Michael Albinus Date: Sun, 28 Jan 2024 09:31:45 +0000 (+0100) Subject: Handle wrong login program in Tramp X-Git-Tag: archive/raspbian/1%29.4+1-4+rpi1~1^2~2^2~18^2~84 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=e11c9f9c6e843779c4b69097490dd78de522a79d;p=emacs.git Handle wrong login program in Tramp * lisp/net/tramp-sh.el (tramp-maybe-open-connection): Exit remote shell when login fails. --- diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 38925652376..1301cd633da 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -5340,7 +5340,7 @@ connection if a previous connection has died for some reason." "2>" (tramp-get-remote-null-device previous-hop)) ?l (concat remote-shell " " extra-args " -i")) ;; A restricted shell does not allow "exec". - (when r-shell '("&&" "exit" "||" "exit"))) + (when r-shell '("&&" "exit")) '("||" "exit")) " ")) ;; Send the command.