all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: David Hull <david.hull@openx.com>
Cc: 20233@debbugs.gnu.org
Subject: bug#20233: 24.5rc1; tramp error opening file
Date: Wed, 01 Apr 2015 08:51:32 +0200	[thread overview]
Message-ID: <87fv8kwdcb.fsf@gmx.de> (raw)
In-Reply-To: <CACMKctPn+++gVY0Or0KdgSEdoRVaOwAMVntexQLXX9wmQ3MPYA@mail.gmail.com> (David Hull's message of "Tue, 31 Mar 2015 14:20:41 -0700")

[Please keep the Cc, for the public]

David Hull <david.hull@openx.com> writes:

Hi David,

> The scp command succeeded:
>
> $ cd /tmp
> $ rm -f
> /var/folders/y9/k3f9vqgn73gf64x8ktywlkd10r0222/T/tramp.110640VR.erl
> $ scp -p -q -r -o ControlMaster=auto -o ControlPath='tramp.%r@%h:%p' -
> o ControlPersist=no
> cos6\:/home/david.hull/src/ds-advertiser-server/src/ds_adv_ox3_lineitem_v3.erl
> /var/folders/y9/k3f9vqgn73gf64x8ktywlkd10r0222/T/tramp.110640VR.erl
> $ echo $?
> 0
> $ ls -l
> /var/folders/y9/k3f9vqgn73gf64x8ktywlkd10r0222/T/tramp.110640VR.erl
> -rw-r--r-- 1 david.hull staff 11905 Mar 31 14:02
> /var/folders/y9/k3f9vqgn73gf64x8ktywlkd10r0222/T/tramp.110640VR.erl
>
> I wonder if the problem could be that the ControlPath option doesn't
> specify a directory?

Yes, indeed. This was changed back in February due to Bug#19861.

> I did a test. I put a "scp" shell script in my $HOME/bin directory
> with the following contents:
>
> #! /bin/bash
> WD=`pwd`
> echo "$WD: scp $*" >>/tmp/scp.out
> /usr/bin/scp "$@"
>
> When I attempted to use tramp, /tmp/scp.out had the following
> contents:
>
> /: scp -p -q -r -o ControlMaster=auto -o ControlPath=tramp.%r@%h:%p -o
> ControlPersist=no
> cos6:/home/david.hull/src/ds-advertiser-server/src/ds_adv_ox3_lineitem_v3.erl
> /var/folders/y9/k3f9vqgn73gf64x8ktywlkd10r0222/T/tramp.16189hTW.erl
>
> Note that the first thing on the line, the working directory, is "/".

Could you, pls, check whether the following patch works for you? It is a
backport from Emacs 25.0.50:

--8<---------------cut here---------------start------------->8---
*** /home/albinus/src/emacs-24/lisp/net/tramp.el.~emacs-24~	2015-04-01 08:47:21.556209883 +0200
--- /home/albinus/src/emacs-24/lisp/net/tramp.el	2015-04-01 08:47:21.660211724 +0200
***************
*** 3355,3364 ****
  
  (defun tramp-handle-unhandled-file-name-directory (_filename)
    "Like `unhandled-file-name-directory' for Tramp files."
!   ;; With Emacs 23, we could simply return `nil'.  But we must keep it
!   ;; for backward compatibility.  "~/" cannot be returned, because
!   ;; there might be machines without a HOME directory (like hydra).
!   "/")
  
  (defun tramp-handle-set-visited-file-modtime (&optional time-list)
    "Like `set-visited-file-modtime' for Tramp files."
--- 3355,3365 ----
  
  (defun tramp-handle-unhandled-file-name-directory (_filename)
    "Like `unhandled-file-name-directory' for Tramp files."
!   ;; Starting with Emacs 23, we must simply return `nil'.  But we must
!   ;; keep backward compatibility, also with XEmacs.  "~/" cannot be
!   ;; returned, because there might be machines without a HOME
!   ;; directory (like hydra).
!   (and (< emacs-major-version 23) "/"))
  
  (defun tramp-handle-set-visited-file-modtime (&optional time-list)
    "Like `set-visited-file-modtime' for Tramp files."
--8<---------------cut here---------------end--------------->8---

Best regards, Michael.





  parent reply	other threads:[~2015-04-01  6:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-30 17:05 bug#20233: 24.5rc1; tramp error opening file David Hull
2015-03-31  6:31 ` Michael Albinus
     [not found]   ` <CACMKctMFUVfqYp1AqT4snRiiAKe0gd21XtDOnrb4r7F0YuoxsA@mail.gmail.com>
     [not found]     ` <87twx1rpcf.fsf@gmx.de>
     [not found]       ` <CACMKctPn+++gVY0Or0KdgSEdoRVaOwAMVntexQLXX9wmQ3MPYA@mail.gmail.com>
2015-04-01  6:51         ` Michael Albinus [this message]
2015-04-01 16:35           ` David Hull
2015-04-01 17:32             ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87fv8kwdcb.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=20233@debbugs.gnu.org \
    --cc=david.hull@openx.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.