]> git.eshelyaron.com Git - emacs.git/commitdiff
(dired-compare-directories): Remove "." and ".." from the alists.
authorRichard M. Stallman <rms@gnu.org>
Mon, 11 Jul 2005 04:25:01 +0000 (04:25 +0000)
committerRichard M. Stallman <rms@gnu.org>
Mon, 11 Jul 2005 04:25:01 +0000 (04:25 +0000)
lisp/ChangeLog
lisp/dired-aux.el

index 5f6f751ec5b9c4d23da72302bd0e793f355ca133..b99648474e4fe21c87ccb36ea4591aa5c4661f3c 100644 (file)
@@ -1,5 +1,8 @@
 2005-07-11  Richard M. Stallman  <rms@gnu.org>
 
+       * dired-aux.el (dired-compare-directories): Remove "." and ".."
+       from the alists.
+
        * emacs-lisp/edebug.el (edebug-slow-after, edebug-slow-before):
        Do nothing if edebug-active.
 
index c9d5c22ded3dae79e80b5f7af1f351ff14edf25a..617cb38585f932b4c4d0711db63e76860c920a42 100644 (file)
@@ -126,16 +126,21 @@ Examples of PREDICATE:
   (let* ((dir1 (dired-current-directory))
          (file-alist1 (dired-files-attributes dir1))
          (file-alist2 (dired-files-attributes dir2))
-        (file-list1 (mapcar
+        file-list1 file-list2)
+    (setq file-alist1 (delq (assoc "." file-alist1) file-alist1))
+    (setq file-alist1 (delq (assoc ".." file-alist1) file-alist1))
+    (setq file-alist2 (delq (assoc "." file-alist2) file-alist2))
+    (setq file-alist2 (delq (assoc ".." file-alist2) file-alist2))
+    (setq file-list1 (mapcar
                      'cadr
                       (dired-file-set-difference
                        file-alist1 file-alist2
-                      predicate)))
-        (file-list2 (mapcar
+                      predicate))
+         file-list2 (mapcar
                      'cadr
                       (dired-file-set-difference
                        file-alist2 file-alist1
-                      predicate))))
+                      predicate)))
     (dired-fun-in-all-buffers
      dir1 nil
      (lambda ()