From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#34834: 26.1; Remote `eshell/mv' and `eshell/cp' on Windows: Opening output file: Invalid argument, c:/home/ ... Date: Thu, 28 Mar 2019 19:52:44 +0200 Message-ID: <83lg0ykhsj.fsf@gnu.org> References: <87o96f4v47.fsf@gmx.com> <871s2qsxli.fsf@gmx.de> Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="232016"; mail-complaints-to="usenet@blaine.gmane.org" Cc: jordan.t.wilson@gmx.com, 34834@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Mar 28 19:10:45 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h9ZUC-000yGZ-G4 for geb-bug-gnu-emacs@m.gmane.org; Thu, 28 Mar 2019 19:10:44 +0100 Original-Received: from localhost ([127.0.0.1]:40134 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h9ZUB-0008Ku-HG for geb-bug-gnu-emacs@m.gmane.org; Thu, 28 Mar 2019 14:10:43 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:40982) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h9ZSQ-0006FB-AC for bug-gnu-emacs@gnu.org; Thu, 28 Mar 2019 14:08:55 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h9ZD4-0006ZE-Ly for bug-gnu-emacs@gnu.org; Thu, 28 Mar 2019 13:53:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:49334) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1h9ZD4-0006ZA-Ff for bug-gnu-emacs@gnu.org; Thu, 28 Mar 2019 13:53:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1h9ZD4-0002bR-EQ for bug-gnu-emacs@gnu.org; Thu, 28 Mar 2019 13:53:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 28 Mar 2019 17:53:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 34834 X-GNU-PR-Package: emacs Original-Received: via spool by 34834-submit@debbugs.gnu.org id=B34834.15537955749989 (code B ref 34834); Thu, 28 Mar 2019 17:53:02 +0000 Original-Received: (at 34834) by debbugs.gnu.org; 28 Mar 2019 17:52:54 +0000 Original-Received: from localhost ([127.0.0.1]:34645 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1h9ZCw-0002b3-1I for submit@debbugs.gnu.org; Thu, 28 Mar 2019 13:52:54 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:52348) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1h9ZCu-0002aq-F5 for 34834@debbugs.gnu.org; Thu, 28 Mar 2019 13:52:52 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:41014) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h9ZCp-0006Gh-3M; Thu, 28 Mar 2019 13:52:47 -0400 Original-Received: from [176.228.60.248] (port=4113 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1h9ZCo-000816-Bf; Thu, 28 Mar 2019 13:52:46 -0400 In-reply-to: <871s2qsxli.fsf@gmx.de> (message from Michael Albinus on Thu, 28 Mar 2019 18:44:09 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:156889 Archived-At: > From: Michael Albinus > Date: Thu, 28 Mar 2019 18:44:09 +0100 > Cc: 34834@debbugs.gnu.org > > --8<---------------cut here---------------start------------->8--- > C-x C-f /plinkx:detlefx:/home/albinus/ ;; This is a remote GNU/Linux machine. > > M-: (expand-file-name "123" "tmp/") ;; 123 is a file, tmp is a directory there. > > => "c:/plinkx:detlefx:/home/albinus/tmp/123" > --8<---------------cut here---------------end--------------->8--- > > I have added traces to this, with M-x trace-function-background for > expand-file-name, tramp-sh-handle-expand-file-name, and > tramp-file-name-handler. The latter function is Tramp's outmost > function. The traces look like this: > > ====================================================================== > 1 -> (expand-file-name "123" "tmp/") > | 2 -> (tramp-file-name-handler expand-file-name "tmp/" "/plinkx:detlefx:/home/albinus/") > | | 3 -> (tramp-sh-handle-expand-file-name "tmp/" "/plinkx:detlefx:/home/albinus/") > | | | 4 -> (tramp-file-name-handler file-name-as-directory "/plinkx:detlefx:/home/albinus/") > | | | 4 <- tramp-file-name-handler: "/plinkx:detlefx:/home/albinus/" > | | | 4 -> (expand-file-name "/home/albinus/tmp/") > | | | 4 <- expand-file-name: "c:/home/albinus/tmp/" > | | 3 <- tramp-sh-handle-expand-file-name: "/plinkx:detlefx:/home/albinus/tmp/" > | 2 <- tramp-file-name-handler: "/plinkx:detlefx:/home/albinus/tmp/" > 1 <- expand-file-name: "c:/plinkx:detlefx:/home/albinus/tmp/123" > ====================================================================== > > Looks, like Tramp returns the proper value "/plinkx:detlefx:/home/albinus/tmp/", > and then in its way through expand-file-name the drive letter is > added. Since this is a C function, I'm not able to debug further. > > Eli, could you pls check this? I don't think I understand what should I check. In general a file name like "/foo/bar" will have a drive letter added to it by expand-file-name. What makes this case special?