]> git.eshelyaron.com Git - emacs.git/commitdiff
Actually delete markers in dired-do-flagged-delete
authorStefan Kangas <stefankangas@gmail.com>
Sun, 2 Oct 2022 22:13:56 +0000 (00:13 +0200)
committerStefan Kangas <stefankangas@gmail.com>
Sun, 2 Oct 2022 22:18:27 +0000 (00:18 +0200)
* lisp/dired.el (dired-do-flagged-delete): Actually delete
markers.  (Bug#58256)

lisp/dired.el

index b9e89292e250795d83da162a64ac258f5e015e02..96b580d57634d764351ec6229f33247f8c610bb5 100644 (file)
@@ -3664,16 +3664,16 @@ non-empty directories is allowed."
         case-fold-search markers)
     (if (save-excursion (goto-char (point-min))
                        (re-search-forward regexp nil t))
-       (dired-internal-do-deletions
-         (nreverse
-         ;; this can't move point since ARG is nil
-         (dired-map-over-marks (cons (dired-get-filename)
-                                      (let ((m (point-marker)))
-                                        (push m markers)
-                                        m))
-                               nil))
-        nil t)
-      (dolist (m markers) (set-marker m nil))
+        (progn
+          (dired-internal-do-deletions
+           (nreverse
+            (dired-map-over-marks (cons (dired-get-filename)
+                                   (let ((m (point-marker)))
+                                     (push m markers)
+                                     m))
+                             nil))
+           nil t)
+          (dolist (m markers) (set-marker m nil)))
       (or nomessage
          (message "(No deletions requested)")))))