From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Albinus Newsgroups: gmane.emacs.bugs Subject: bug#10489: 24.0.92; dired-do-copy may create infinite directory hierarchy Date: Sun, 15 Jan 2012 20:49:18 +0100 Message-ID: <87pqek9269.fsf@gmx.de> References: <87mx9su32g.fsf@web.de> <87sjjkfvwt.fsf@gmail.com> <8362ggkquq.fsf@gnu.org> <87lipcrlga.fsf@gmail.com> <87fwfkc4pn.fsf@gmx.de> <87fwfjsw8t.fsf@gmail.com> <87aa5rdazl.fsf@gmx.de> <87d3anogf5.fsf@gmail.com> <011AEED9E81C4DEFA6B1E03B0F57F28F@us.oracle.com> <878vlbljnc.fsf@gmx.de> <8739bj8mu1.fsf@gmail.com> <87fwfjo24c.fsf@gmx.de> <87pqen76p4.fsf@gmail.com> <83fwfik92e.fsf@gnu.org> <87mx9q1sz7.fsf@gmail.com> <87vcodm8ns.fsf@gmx.de> <87pqekopb5.fsf@gmail.com> <87hazwoost.fsf@gmail.com> <87ty3w9639.fsf@gmx.de> <8762gckckt.fsf@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1326657024 20568 80.91.229.12 (15 Jan 2012 19:50:24 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 15 Jan 2012 19:50:24 +0000 (UTC) Cc: 10489@debbugs.gnu.org To: Thierry Volpiatto Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jan 15 20:50:19 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RmW5q-000690-3r for geb-bug-gnu-emacs@m.gmane.org; Sun, 15 Jan 2012 20:50:18 +0100 Original-Received: from localhost ([::1]:44251 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RmW5p-0004ZR-44 for geb-bug-gnu-emacs@m.gmane.org; Sun, 15 Jan 2012 14:50:17 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:60420) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RmW5l-0004ZG-GG for bug-gnu-emacs@gnu.org; Sun, 15 Jan 2012 14:50:15 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RmW5k-00060A-EH for bug-gnu-emacs@gnu.org; Sun, 15 Jan 2012 14:50:13 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:36002) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RmW5k-000606-BJ for bug-gnu-emacs@gnu.org; Sun, 15 Jan 2012 14:50:12 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1RmW6X-0006lC-LH for bug-gnu-emacs@gnu.org; Sun, 15 Jan 2012 14:51:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Michael Albinus Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 15 Jan 2012 19:51:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 10489 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 10489-submit@debbugs.gnu.org id=B10489.132665701725932 (code B ref 10489); Sun, 15 Jan 2012 19:51:01 +0000 Original-Received: (at 10489) by debbugs.gnu.org; 15 Jan 2012 19:50:17 +0000 Original-Received: from localhost ([127.0.0.1]:58908 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1RmW5o-0006kD-NS for submit@debbugs.gnu.org; Sun, 15 Jan 2012 14:50:17 -0500 Original-Received: from mailout-de.gmx.net ([213.165.64.23]:38523) by debbugs.gnu.org with smtp (Exim 4.72) (envelope-from ) id 1RmW5l-0006k4-9r for 10489@debbugs.gnu.org; Sun, 15 Jan 2012 14:50:14 -0500 Original-Received: (qmail invoked by alias); 15 Jan 2012 19:49:21 -0000 Original-Received: from p57BB9257.dip0.t-ipconnect.de (EHLO detlef.gmx.de) [87.187.146.87] by mail.gmx.net (mp015) with SMTP; 15 Jan 2012 20:49:21 +0100 X-Authenticated: #3708877 X-Provags-ID: V01U2FsdGVkX19qhBl2VD1qfCjrkpCSbxI2UoB0O8u9/iEAvZpFhv lS54Q0DHugpqOW In-Reply-To: <8762gckckt.fsf@gmail.com> (Thierry Volpiatto's message of "Sun, 15 Jan 2012 20:09:06 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.92 (gnu/linux) X-Y-GMX-Trusted: 0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:55775 Archived-At: Thierry Volpiatto writes: > IMHO we should fix this bug for most use cases with a compare function > maybe not perfect in many points but ok for most basic usages. > The function shown by Drew and I put in last patch as you said isn't > sufficient and fail in many cases even on local filesystem: > > (defun bmkp-same-file-p (file1 file2) > "Return non-nil if FILE1 and FILE2 name the same file. > If either name is not absolute, then it is expanded relative to > `default-directory' for the test." > (and (equal (file-remote-p file1) (file-remote-p file2)) > (string= (file-truename (expand-file-name file1)) > (file-truename (expand-file-name file2))))) > > (bmkp-same-file-p "~/Test" "/home/thierry/Test/") => nil So it must be (string= (directory-file-name (file-truename (expand-file-name file1))) (directory-file-name (file-truename (expand-file-name file2)))))) Best regards, Michael.