]> git.eshelyaron.com Git - emacs.git/commitdiff
(rmail-get-attr-names): Give a warning rather than an error if the
authorGlenn Morris <rgm@gnu.org>
Tue, 17 Feb 2009 02:37:40 +0000 (02:37 +0000)
committerGlenn Morris <rgm@gnu.org>
Tue, 17 Feb 2009 02:37:40 +0000 (02:37 +0000)
header is corrupt.

lisp/ChangeLog
lisp/mail/rmail.el

index 093bd0fa8e139e4cab0a59a26a0ef5731f7e7462..735e91e99e3f76f35f3d6f168aacf81b59b7bca1 100644 (file)
@@ -1,3 +1,13 @@
+2009-02-17  Glenn Morris  <rgm@gnu.org>
+
+       * mail/rmailout.el (rmail-fields-not-to-output): Doc fix.
+       (rmail-delete-unwanted-fields): Ignore case.  Use line-beg-pos.
+       (rmail-output, rmail-output-as-seen): Change the "from-gnus" argument to
+       "not-rmail", and make it work.  Simplify.
+
+       * mail/rmail.el (rmail-get-attr-names): Give a warning rather than an
+       error if the header is corrupt.
+
 2009-02-16  Ulf Jasper  <ulf.jasper@web.de>
 
        * net/newst-treeview.el (newsticker--treeview-load): Offer
index 9ba9accd0d35c2aa35c8c0177371de5b058d21dd..50ea344785f991189dbae8df030c8f6b86e3dca7 100644 (file)
@@ -2054,16 +2054,16 @@ If MSG is nil, use the current message."
        (nmax (length rmail-attr-array))
        result temp)
     (when value
-      (unless (= (length value) nmax)
-       (error "Corrupt attribute header in message"))
-      (dotimes (index nmax)
-       (setq temp (and (not (= ?- (aref value index)))
-                       (nth 1 (aref rmail-attr-array index)))
-             result
-             (cond
-              ((and temp result) (format "%s, %s" result temp))
-              (temp temp)
-              (t result))))
+      (if (/= (length value) nmax)
+          (message "Warning: corrupt attribute header in message")
+        (dotimes (index nmax)
+          (setq temp (and (not (= ?- (aref value index)))
+                          (nth 1 (aref rmail-attr-array index)))
+                result
+                (cond
+                 ((and temp result) (format "%s, %s" result temp))
+                 (temp temp)
+                 (t result)))))
       result)))
 
 (defun rmail-get-keywords (&optional msg)