GNOME Bugzilla – Bug 431472
Copy/move should not replace a file by itself
Last modified: 2008-02-18 18:48:00 UTC
[ Forwarded from http://bugs.debian.org/419525 by Dieter Lucking ] Doing this; cd /tmp/ echo > a ln -s /tmp cd tmp mv a /tmp/ Gives me: mv: `a' and `/tmp/a' are the same file Replacing /tmp/a with /tmp/tmp/a in nautilus leads to deletion - copy/paste, cut/paste or drag/drop will do it. === This bug leads to user data loss in this very rare case.
Created attachment 86662 [details] [review] Abort when overwriting a file by itself This patch aborts the transfer when the source and destination are the same file (be it because of a hard link or a symbolic link manipulation like the user described).
FYI doesn't seem to apply against 2.21.1 anymore. :-/ I guess this patch has been victim of the new "common progress bar" dialog.
This seems to be fixed in 2.21.91, clicking on Replace replaces the file just fine. Please reopen this bug and move it in the GIO component of nautilus bugzilla if it happens again, thanks!