From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Patch for Emacs 25.2 Date: Tue, 17 Jan 2017 17:58:58 +0200 Message-ID: <83y3y98ypp.fsf@gnu.org> References: <87o9z7s5iq.fsf@gmx.de> <83eg039e93.fsf@gnu.org> <87eg024qvh.fsf@gmx.de> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1484668768 31385 195.159.176.226 (17 Jan 2017 15:59:28 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 17 Jan 2017 15:59:28 +0000 (UTC) Cc: emacs-devel@gnu.org To: Michael Albinus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jan 17 16:59:23 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cTWAK-0007Xh-AC for ged-emacs-devel@m.gmane.org; Tue, 17 Jan 2017 16:59:20 +0100 Original-Received: from localhost ([::1]:36240 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTWAO-0005Fx-WC for ged-emacs-devel@m.gmane.org; Tue, 17 Jan 2017 10:59:25 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44529) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTWAI-0005Fr-Qd for emacs-devel@gnu.org; Tue, 17 Jan 2017 10:59:19 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cTWAE-0000be-8Q for emacs-devel@gnu.org; Tue, 17 Jan 2017 10:59:18 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39152) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTWAE-0000bS-5V; Tue, 17 Jan 2017 10:59:14 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4674 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cTWAD-0003MI-Et; Tue, 17 Jan 2017 10:59:13 -0500 In-reply-to: <87eg024qvh.fsf@gmx.de> (message from Michael Albinus on Mon, 16 Jan 2017 22:49:38 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:211349 Archived-At: > From: Michael Albinus > Cc: emacs-devel@gnu.org > Date: Mon, 16 Jan 2017 22:49:38 +0100 > > In `make-auto-save-file-name', there is twice a test for ang-ftp file names: > > --8<---------------cut here---------------start------------->8--- > (not (string-match "^/\\w+@[-A-Za-z0-9._]+:" result))) > --8<---------------cut here---------------end--------------->8--- > > The regexp matches ange-ftp file names like "/user@host:". It does not > match general Tramp syntax, like "/method:user@host:" or "/host:". As > result, on MS Windows there is an error like > > --8<---------------cut here---------------start------------->8--- > (let ((buffer-file-name "/method:user@host:/path/to/file") > tramp-auto-save-directory auto-save-file-name-transforms) > (make-auto-save-file-name)) > > => "\\method!user@host!\\path\\to\\#file#" > --8<---------------cut here---------------end--------------->8--- > > The patch replaces this regexp by > > --8<---------------cut here---------------start------------->8--- > (not (file-remote-p result))) > --8<---------------cut here---------------end--------------->8--- > > Then it works as expected: > > --8<---------------cut here---------------start------------->8--- > (let ((buffer-file-name "/method:user@host:/path/to/file") > tramp-auto-save-directory auto-save-file-name-transforms) > (make-auto-save-file-name)) > > => "/method:user@host:/path/to/#file#" > --8<---------------cut here---------------end--------------->8--- > > The patch is harmless enough that I propose it for Emacs 25.2. I see your point, but as the current code exists for quite some time (more than 11 years), I think we can live with it for one more Emacs release. So let's leave this out for Emacs 25.2. Thanks.