Stacey Marshall <stacey.marsh...@gmail.com> writes:

Hi Stacey,

> Cirlcing back to remote command execution command line length issue
> seen with tramp upon connection to Solaris host.

Thanks for your exhaustive analysis. Since I have no access to Solaris
for testing, I trust what Tramp users contribute.

> For a simple test then I modified tramp-sh-handle-make-process to
> always apply it:

Good catch. However, I would restrict this to disable buffering also for
Solaris, see appended patch. It uses tramp-sunos-unames in order to
check, whether the remote system runs Solaris. ATM, this constant covers
"SunOS 5.10" and "SunOS 5.11" on the remote side, being the output of
'uname -sr'. Does this match also your sequoia 15.4.1 system? Otherwise,
tramp-sunos-unames must be extended.

> For the moment I shall carry-on and see what breaks, but hopefully
> more of what works now!

Thanks, and pls check, whether my patch would be sufficient.

Best regards, Michael.

diff --git a/lisp/tramp-sh.el b/lisp/tramp-sh.el
index 9d74c2fd..046eef79 100644
--- a/lisp/tramp-sh.el
+++ b/lisp/tramp-sh.el
@@ -3115,7 +3115,9 @@ will be used."
 			(let ((pid (tramp-send-command-and-read v "echo $$")))
 			  (setq p (tramp-get-connection-process v))
 			  (process-put p 'remote-pid pid))
-			(when (memq connection-type '(nil pipe))
+			(when
+			    (or (memq connection-type '(nil pipe))
+				(tramp-check-remote-uname v tramp-sunos-unames))
 			  ;; Disable carriage return to newline
 			  ;; translation.  This does not work on
 			  ;; macOS, see Bug#50748.
@@ -3131,6 +3133,9 @@ will be used."
 			  ;; should set a timeout
 			  ;; instead.  See `tramp-pipe-stty-settings'.
 			  ;; (Bug#62093)
+			  ;; On Solaris, the maximum line length
+			  ;; depends also on MAX_CANON (256).  So we
+			  ;; disable buffering as well.
 			  ;; FIXME: Shall we rather use "stty raw"?
 			  (tramp-send-command
 			   v (format

Reply via email to