Andrew Hii <hiichiile...@gmail.com> writes: Hi Andrew,
Thank you for the bug report! > I tried ssh from the linux machine to qnx target via terminal and it > works. After inspecting tramp debug log, tramp seems to fail at > tramp-set-remote-path function where it happens after it gets the > result of > "getconf PIPE_BUF ./" from qnx target. > > I executed the command on the qnx target and get a result as follow: > > # getconf PIPE_BUF / 2>/dev/null || echo 4096 2>/dev/null; > undefined > 4096 Indeed, there's the problem. Could you, pls, install Tramp 2.7.2 from GNU ELPA, and apply the appended patch? This should fix the problem. Best regards, Michael.
diff --git a/lisp/tramp-sh.el b/lisp/tramp-sh.el index 07b4daf4..09351051 100644 --- a/lisp/tramp-sh.el +++ b/lisp/tramp-sh.el @@ -5639,6 +5639,7 @@ Nonexistent directories are removed from spec." ;; - 8 KiB on HP-UX, Plan9. ;; - 10 KiB on IRIX. ;; - 32 KiB on AIX, Minix. +;; - 'undefined' on QNX. ;; [1] https://pubs.opengroup.org/onlinepubs/9699919799/functions/write.html ;; [2] https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/limits.h.html ;; See Bug#65324. @@ -5646,11 +5647,14 @@ Nonexistent directories are removed from spec." (defun tramp-get-remote-pipe-buf (vec) "Return PIPE_BUF config from the remote side." (with-tramp-connection-property vec "pipe-buf" - (tramp-send-command-and-read - vec - (format "getconf PIPE_BUF / 2>%s || echo 4096" - (tramp-get-remote-null-device vec)) - 'noerror))) + (let ((result + (tramp-send-command-and-read + vec (format "getconf PIPE_BUF / 2>%s || echo 4096" + (tramp-get-remote-null-device vec)) + 'noerror))) + (unless (natnump result) + (setq result 4096)) + result))) (defun tramp-get-remote-locale (vec) "Determine remote locale, supporting UTF8 if possible."