From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Martin von Gagern Newsgroups: gmane.emacs.bugs Subject: Re: backup-buffer-copy loops if old backup can't be deleted Date: Tue, 21 Aug 2007 16:51:27 +0200 Message-ID: <46CAFBEF.2040606@gmx.net> References: <46CAD810.3050904@gmx.net> <46CAF8AC.9070809@gmx.at> Reply-To: bug-gnu-emacs@gnu.org, Martin von Gagern NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1345626063==" X-Trace: sea.gmane.org 1187707902 31857 80.91.229.12 (21 Aug 2007 14:51:42 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 21 Aug 2007 14:51:42 +0000 (UTC) Cc: bug-gnu-emacs@gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Aug 21 16:51:40 2007 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1INV50-0004ER-Ra for geb-bug-gnu-emacs@m.gmane.org; Tue, 21 Aug 2007 16:51:39 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1INV50-0006MX-Dk for geb-bug-gnu-emacs@m.gmane.org; Tue, 21 Aug 2007 10:51:38 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1INV4y-0006MS-7e for bug-gnu-emacs@gnu.org; Tue, 21 Aug 2007 10:51:36 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1INV4x-0006M9-LM for bug-gnu-emacs@gnu.org; Tue, 21 Aug 2007 10:51:35 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1INV4x-0006M4-DF for bug-gnu-emacs@gnu.org; Tue, 21 Aug 2007 10:51:35 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1INV4x-00080z-8C for bug-gnu-emacs@gnu.org; Tue, 21 Aug 2007 10:51:35 -0400 Original-Received: (qmail invoked by alias); 21 Aug 2007 14:51:33 -0000 Original-Received: from ppp-88-217-44-103.dynamic.mnet-online.de (EHLO [88.217.44.103]) [88.217.44.103] by mail.gmx.net (mp016) with SMTP; 21 Aug 2007 16:51:33 +0200 X-Authenticated: #858129 X-Provags-ID: V01U2FsdGVkX18x4A4bGDgxTFgkBiKw/J5f/Xqd2jLGkZUxGdSnKf nq2rVjR21+WmY7 User-Agent: Thunderbird 2.0.0.6 (X11/20070817) In-Reply-To: <46CAF8AC.9070809@gmx.at> X-Enigmail-Version: 0.95.3 X-Y-GMX-Trusted: 0 X-Detected-Kernel: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:16409 Archived-At: This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --===============1345626063== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig34DC923C1E770578F0BDF37C" This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig34DC923C1E770578F0BDF37C Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable martin rudalics wrote: > Did you apply that patch? Yes, I did, and even got it included in the relevant byte-compiled code. Seems to work well enough here. > Suppose the file to-name exists but cannot be > deleted. `copy-file' will raise its `file-already-exists' error and yo= u > remain trapped in that loop. No, if the file cannot be deleted, the delete-file will signal a file-error so copy-file doesn't even get a chance to signal a file-already-exists error because it doesn't get called at all. As the outer condition-case doesn't catch file-error, the signal will propagate up the call stack. > You have to either change the backup file's permissions from within the= > `condition-case' A possible solution in my simple test case, but not a solution for the real world case where user A wants to edit a file in a dir belonging to B, where B granted write permission to A only for that single file, not for its backup and neither for the directory. Nothing A can da about it. > or mandate error handling up to `backup-buffer' where > it attempts to do the (convert-standard-filename "~/%backup%~") stuff. Already happens like this. > I can't test these solutions here since my file system doesn't provide > permissions. Tough luck. Which system? Isn't even the MS-DOS readonly flag enough for this? Greetings, Martin von Gagern --------------enig34DC923C1E770578F0BDF37C Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGyvvzRhp6o4m9dFsRAv6iAKCNZbjCvNr9taz1nAsn1LF+C6VLmwCeMguv j48mzZPX9HDWVZenQQ7ecTY= =zBCz -----END PGP SIGNATURE----- --------------enig34DC923C1E770578F0BDF37C-- --===============1345626063== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ bug-gnu-emacs mailing list bug-gnu-emacs@gnu.org http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs --===============1345626063==--