* gnus-sum.el (gnus-adjust-marks): Avoid splicing null INTO the
authorKevin Greiner <kevin.greiner@compsol.cc>
Thu, 22 Jan 2004 12:28:23 +0000 (12:28 +0000)
committerKevin Greiner <kevin.greiner@compsol.cc>
Thu, 22 Jan 2004 12:28:23 +0000 (12:28 +0000)
uncompressed list.

lisp/ChangeLog
lisp/gnus-sum.el

index 2b35e2a..fa0134c 100644 (file)
@@ -1,3 +1,8 @@
+2004-01-22  Kevin Greiner <kgreiner@xpediantsolutions.com>
+
+       * gnus-sum.el (gnus-adjust-marks): Avoid splicing null INTO the
+       uncompressed list.
+
 2004-01-22  Jesper Harder  <harder@ifa.au.dk>
 
        * spam-stat.el (spam-stat-strip-xref): New function.
index 801195f..e6dcac1 100644 (file)
@@ -5362,7 +5362,7 @@ If SELECT-ARTICLES, only select those articles from GROUP."
         (min (car active))
         (max (cdr active))
         (types gnus-article-mark-lists)
-        marks var articles article mark mark-type
+        marks var articles article mark mark-type p-articles
          bgn end)
 
     (dolist (marks marked-lists)
@@ -5376,7 +5376,8 @@ If SELECT-ARTICLES, only select those articles from GROUP."
        ;; Adjust "simple" lists - compressed yet unsorted
        ((eq mark-type 'list)
         ;; Simultaneously uncompress and clip to active range
-        (setq articles (cdr marks))
+        (setq p-articles marks
+              articles (cdr p-articles))
         (while (setq article (car articles))
           (when (cond ((consp article)
                        (setq bgn (max (car article) min)
@@ -5388,19 +5389,22 @@ If SELECT-ARTICLES, only select those articles from GROUP."
                          (while (<= bgn end)
                            (setq articles (setcdr articles (cons bgn (cdr articles)))
                                  bgn (1+ bgn)))
-                         (setq articles (cdr articles))
+                         (setq p-articles articles
+                               articles (cdr articles))
                          nil))
                       ((or (< article min)
                            (> article max))
                        t        ; value excluded - splice out of marks
                        )
                       (t
-                       (setq articles (cdr articles))
+                       (setq p-articles articles
+                             articles (cdr articles))
                        nil))
-            ; perform slice to remove article
-            (setcar articles (cadr articles))
-            (setcdr articles (cddr articles))))
-          (set var (cdr marks)))
+            ;; perform slice to remove article
+            (if (setcar articles (cadr articles))
+                (setcdr articles (cddr articles))
+              (setcdr p-articles nil))))
+        (set var (cdr marks)))
        ;; Adjust assocs.
        ((eq mark-type 'tuple)
        (set var (setq articles (cdr marks)))