GNU bug report logs - #20118
25.0.50; tramp-test29-vc-registered aborts on Cygwin

Previous Next

Package: emacs;

Reported by: Ken Brown <kbrown <at> cornell.edu>

Date: Mon, 16 Mar 2015 16:00:06 UTC

Severity: normal

Tags: fixed

Found in version 25.0.50

Fixed in version 25.1

Done: Michael Albinus <michael.albinus <at> gmx.de>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 20118 <at> debbugs.gnu.org (full text, mbox):

From: Michael Albinus <michael.albinus <at> gmx.de>
To: Ken Brown <kbrown <at> cornell.edu>
Cc: 20118 <at> debbugs.gnu.org
Subject: Re: bug#20118: 25.0.50; tramp-test29-vc-registered aborts on Cygwin
Date: Tue, 17 Mar 2015 11:36:41 +0100
Ken Brown <kbrown <at> cornell.edu> writes:

>>> The outward symptom is almost identical to that of Bug#20117, but I
>>> don't know if the present bug is related, because it's been happening
>>> for as long as I can remember; I just never got around to reporting it.
>>>
>>> Test tramp-test29-vc-registered aborted with non-local exit
>>>    ABORTED  30/41  tramp-test29-vc-registered
>>
>> Please instrument it similar to the recipe in bug#20117.
>
> Output attached.

Well, this bug is different from Bug#20117. A shell function Tramp sends
to the remote host contains some lines with leading TABs. Your bash tries
to expand them.

The following patch shall fix this.

--8<---------------cut here---------------start------------->8---
*** /home/albinus/src/tramp/lisp/tramp-sh.el.~master~	2015-03-17 11:25:13.857882111 +0100
--- /home/albinus/src/tramp/lisp/tramp-sh.el	2015-03-17 11:24:45.233315481 +0100
***************
*** 3725,3730 ****
--- 3725,3734 ----
  		  (tramp-get-connection-process vec) "scripts" nil)))
      (unless (member name scripts)
        (with-tramp-progress-reporter vec 5 (format "Sending script `%s'" name)
+ 	;; In bash, leading TABs like in `tramp-vc-registered-read-file-names'
+ 	;; could result in unwanted command expansion.  Avoid this.
+ 	(setq script (tramp-compat-replace-regexp-in-string
+ 		      (make-string 1 ?\t) (make-string 8 ? ) script))
  	;; The script could contain a call of Perl.  This is masked with `%s'.
  	(when (and (string-match "%s" script)
  		   (not (tramp-get-remote-perl vec)))
--8<---------------cut here---------------end--------------->8---

> Ken

Best regards, Michael.




This bug report was last modified 10 years and 71 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.