GNU bug report logs - #10489
24.0.92; dired-do-copy may create infinite directory hierarchy

Previous Next

Package: emacs;

Reported by: michael_heerdegen <at> web.de

Date: Thu, 12 Jan 2012 19:36:01 UTC

Severity: important

Tags: patch

Merged with 11130

Found in version 24.0.92

Done: Chong Yidong <cyd <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #139 received at 10489 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Thierry Volpiatto <thierry.volpiatto <at> gmail.com>
Cc: 10489 <at> debbugs.gnu.org, michael.albinus <at> gmx.de
Subject: Re: bug#10489: 24.0.92;
	dired-do-copy may create infinite directory hierarchy
Date: Sat, 14 Jan 2012 10:00:25 +0200
> From: Thierry Volpiatto <thierry.volpiatto <at> gmail.com>
> Date: Fri, 13 Jan 2012 20:17:43 +0100
> Cc: 10489 <at> debbugs.gnu.org
> 
>  (defun dired-copy-file-recursive (from to ok-flag &optional
>  				       preserve-time top recursive)
> -  (let ((attrs (file-attributes from)))
> +  (let* ((case-fold-search t)
> +         (fromname    (file-name-as-directory (file-truename from)))
> +         (destname    (file-name-as-directory (file-truename to)))
> +         (rem-dirname (and (equal "sudo" (file-remote-p fromname 'method))
> +                           (file-remote-p fromname 'localname)))
> +         (rem-newname (and (equal "sudo" (file-remote-p destname 'method))
> +                           (file-remote-p destname 'localname)))
> +         (attrs       (file-attributes from)))
> +    (when (equal (or rem-dirname fromname)
> +                 (or rem-newname destname))
> +      (error "Can't copy directory `%s' on itself" from))

Why is case-fold-search being unconditionally bound to t?  I don't
think this is TRT on case-sensitive filesystems.  Am I missing
something?




This bug report was last modified 13 years and 58 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.