Subject: bug#41099: 28.0.50; TRAMP process-file ignores exit status of remote process

From: Noam Postavsky <[email-masked]>
Date: Wed, 13 May 2020 21:39:33 -0400

Michael Albinus <[email-masked]> writes:

> Philipp Stephani <[email-masked]> writes:
>
>> (defun tramp-process-file (...)
>>   (let ((code (...original code...)))
>>     (if (> code 128)
>>        ;; Probably a signal
>>        (format "Signal %d" (- code 128))
>>     code))
>
> I've pushed a patch to master along these lines.

I don't think this is sufficiently reliable.  With current master:

    (let ((default-directory "/sudo::/home/npostavs/.emacs.d/"))
      (process-file "git" nil nil nil "merge-base"))
    ;=> "Signal 1"

    (let ((default-directory "/home/npostavs/.emacs.d/"))
      (process-file "git" nil nil nil "merge-base"))
    ;=> 129