diff options
| author | Chong Yidong | 2008-12-28 03:24:53 +0000 |
|---|---|---|
| committer | Chong Yidong | 2008-12-28 03:24:53 +0000 |
| commit | d5ac5779a4bc0ef96d39eda5ca0cee80f5ee0191 (patch) | |
| tree | a6124423d0ce0382c62f88928ad3c4d00bfdd6a8 | |
| parent | 7d96af1ab4d9e76259b4d32a63ea05cf4ec6ff2f (diff) | |
| download | emacs-d5ac5779a4bc0ef96d39eda5ca0cee80f5ee0191.tar.gz emacs-d5ac5779a4bc0ef96d39eda5ca0cee80f5ee0191.zip | |
(move-file-to-trash): Bind backup-directory-alist to nil before
uniquifying backup trash file name.
| -rw-r--r-- | lisp/files.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/files.el b/lisp/files.el index f8ebaa6c605..1f1640e24ba 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -5992,7 +5992,8 @@ Returns nil on success." | |||
| 5992 | (and (file-exists-p new-fn) | 5992 | (and (file-exists-p new-fn) |
| 5993 | ;; make new-fn unique. | 5993 | ;; make new-fn unique. |
| 5994 | ;; example: "~/.Trash/abc.txt" -> "~/.Trash/abc.txt.~1~" | 5994 | ;; example: "~/.Trash/abc.txt" -> "~/.Trash/abc.txt.~1~" |
| 5995 | (let ((version-control t)) | 5995 | (let ((version-control t) |
| 5996 | (backup-directory-alist nil)) | ||
| 5996 | (setq new-fn (car (find-backup-file-name new-fn))))) | 5997 | (setq new-fn (car (find-backup-file-name new-fn))))) |
| 5997 | ;; stop processing if fn is same or parent directory of trash-dir. | 5998 | ;; stop processing if fn is same or parent directory of trash-dir. |
| 5998 | (and (string-match fn trash-dir) | 5999 | (and (string-match fn trash-dir) |