]> git.eshelyaron.com Git - emacs.git/commitdiff
Update gnus/nnselect marks only for current articles
authorAndrew G Cohen <cohen@andy.bu.edu>
Wed, 29 Mar 2023 06:05:59 +0000 (14:05 +0800)
committerAndrew G Cohen <cohen@andy.bu.edu>
Sun, 9 Apr 2023 06:23:34 +0000 (14:23 +0800)
* lisp/gnus/nnselect.el (nnselect-push-info): Restrict updating of
marked articles to those whose headers have been retrieved, taking
care to handle 'tuples.

lisp/gnus/nnselect.el

index 4680cf23e5ebf7859a7650f9fdecc969978cdb40..9a2957c9f521984c3666af78ecf8bfbc2700bb9c 100644 (file)
@@ -895,13 +895,17 @@ article came from is also searched."
     ;; collect the set of marked article lists categorized by
     ;; originating groups
     (pcase-dolist (`(,mark . ,type) gnus-article-mark-lists)
-      (let (type-list)
-       (when (setq type-list
-                   (symbol-value (intern (format "gnus-newsgroup-%s" mark))))
-         (push (cons
-                type
-                (numbers-by-group type-list (gnus-article-mark-to-type type)))
-               mark-list))))
+      (let ((mark-type (gnus-article-mark-to-type type))
+            (type-list (symbol-value
+                        (intern (format "gnus-newsgroup-%s" mark)))))
+        (when type-list
+          (unless (eq 'tuple mark-type)
+            (setq type-list (range-list-intersection
+                             gnus-newsgroup-articles type-list)))
+          (push (cons
+                 type
+                 (numbers-by-group type-list mark-type))
+                mark-list))))
     ;; now work on each originating group one at a time
     (pcase-dolist (`(,artgroup . ,artlist)
                   (numbers-by-group gnus-newsgroup-articles))