Michael Albinus wrote:

> (copy-file "~/.emacs" "/tmp/")
>
> Debugger entered--Lisp error: (file-already-exists "File already exists" 
> "/home/albinus/.emacs")
>   copy-file("~/.emacs" "/tmp/")
>   eval((copy-file "~/.emacs" "/tmp/"))
>   eval-expression((copy-file "~/.emacs" "/tmp/") nil)
>   call-interactively(eval-expression)
>
> Of course, "/home/albinus/.emacs" does exists, and "/tmp/.emacs"
> doesn't.

*** fileio.c    31 Jan 2004 04:24:23 -0000      1.497
--- fileio.c    2 Feb 2004 20:19:06 -0000
***************
*** 2407,2413 ****
    CHECK_STRING (newname);
  
    if (!NILP (Ffile_directory_p (newname)))
!     newname = Fexpand_file_name (file, newname);
    else
      newname = Fexpand_file_name (newname, Qnil);
  
--- 2407,2413 ----
    CHECK_STRING (newname);
  
    if (!NILP (Ffile_directory_p (newname)))
!     newname = Fexpand_file_name ( Ffile_name_nondirectory (file), newname);
    else
      newname = Fexpand_file_name (newname, Qnil);


> The problem is not evident with Emacs 21.3.

It barfs for me on 21.3, but then copy-file was not documented as
accepting a directory for NEWNAME in 21.3.


_______________________________________________
Tramp-devel mailing list
[EMAIL PROTECTED]
http://mail.nongnu.org/mailman/listinfo/tramp-devel

Reply via email to