* gnus-util.el (gnus-split-references): accept a nil references
authorTeodor Zlatanov <tzz@lifelogs.com>
Mon, 18 Oct 2004 18:44:58 +0000 (18:44 +0000)
committerTeodor Zlatanov <tzz@lifelogs.com>
Mon, 18 Oct 2004 18:44:58 +0000 (18:44 +0000)
string and go on blissfully

* gnus-registry.el (gnus-registry-split-fancy-with-parent): catch
cases where the references string is non-nil but has no references

lisp/ChangeLog
lisp/gnus-registry.el
lisp/gnus-util.el

index c232b63..3104387 100644 (file)
@@ -1,5 +1,11 @@
 2004-10-18  Teodor Zlatanov  <tzz@lifelogs.com>
 
+       * gnus-util.el (gnus-split-references): accept a nil references
+       string and go on blissfully
+
+       * gnus-registry.el (gnus-registry-split-fancy-with-parent): catch
+       cases where the references string is non-nil but has no references
+
        * encrypt.el: add autoload tags
 
        * spam.el (spam-resolve-registrations-routine): remove article
index bc95112..35347ae 100644 (file)
@@ -369,7 +369,8 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details."
             nnmail-split-fancy-with-parent-ignore-groups
           (list nnmail-split-fancy-with-parent-ignore-groups)))
        references res)
-    (if refstr
+    ;; the references string must be valid and parse to valid references
+    (if (and refstr (gnus-extract-references refstr))
        (progn
          (setq references (nreverse (gnus-extract-references refstr)))
          (mapcar (lambda (x)
index 8c26877..bb03786 100644 (file)
@@ -474,6 +474,7 @@ inside loops."
 (defun gnus-split-references (references)
   "Return a list of Message-IDs in REFERENCES."
   (let ((beg 0)
+       (references (or references ""))
        ids)
     (while (string-match "<[^<]+[^< \t]" references beg)
       (push (substring references (match-beginning 0) (setq beg (match-end 0)))