mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-01-03 10:31:37 -08:00
(Frename_file) [DOS_NT]: Don't try to move directory to itself on DOS_NT
platforms, if the old and new names are identical but for the letter-case.
This commit is contained in:
parent
a1a302fda8
commit
f83caf703c
1 changed files with 7 additions and 1 deletions
|
|
@ -2750,7 +2750,13 @@ This is what happens in interactive use with M-x. */)
|
|||
CHECK_STRING (newname);
|
||||
file = Fexpand_file_name (file, Qnil);
|
||||
|
||||
if (!NILP (Ffile_directory_p (newname)))
|
||||
if ((!NILP (Ffile_directory_p (newname)))
|
||||
#ifdef DOS_NT
|
||||
/* If the file names are identical but for the case,
|
||||
don't attempt to move directory to itself. */
|
||||
&& (NILP (Fstring_equal (Fdowncase (file), Fdowncase (newname))))
|
||||
#endif
|
||||
)
|
||||
newname = Fexpand_file_name (Ffile_name_nondirectory (file), newname);
|
||||
else
|
||||
newname = Fexpand_file_name (newname, Qnil);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue