changeset 91734:119a8eeef82f

(rmail-nonignored-headers): Allow to be nil. (rmail-clear-headers): Don't check `rmail-nonignored-headers' when it is nil.
author Bastien Guerry <bzg@altern.org>
date Sun, 10 Feb 2008 22:10:09 +0000
parents e9326c8f35b0
children 4240048b8e8d
files lisp/ChangeLog lisp/mail/rmail.el
diffstat 2 files changed, 10 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Sun Feb 10 21:59:27 2008 +0000
+++ b/lisp/ChangeLog	Sun Feb 10 22:10:09 2008 +0000
@@ -1,3 +1,9 @@
+2008-02-10  Bastien Guerry  <bzg@altern.org>
+
+	* mail/rmail.el (rmail-nonignored-headers): Allow to be nil.
+	(rmail-clear-headers): Don't check `rmail-nonignored-headers' when
+	it is nil.
+
 2008-02-10  Daiki Ueno  <ueno@unixuser.org>
 
 	* epg-config.el: Expand the contents of epg-package-info.el.
--- a/lisp/mail/rmail.el	Sun Feb 10 21:59:27 2008 +0000
+++ b/lisp/mail/rmail.el	Sun Feb 10 22:10:09 2008 +0000
@@ -299,6 +299,7 @@
   "*Regexp to match X header fields that Rmail should show.
 This regexp overrides `rmail-ignored-headers'; if both this regexp
 and that one match a certain header field, Rmail shows the field.
+If this is nil, ignore all header fields in `rmail-ignored-headers'.
 
 This variable is used for reformatting the message header,
 which normally happens once for each message,
@@ -306,7 +307,7 @@
 To make a change in this variable take effect
 for a message that you have already viewed,
 go to that message and type \\[rmail-toggle-header] twice."
-  :type 'regexp
+  :type '(choice (const nil) (regexp))
   :group 'rmail-headers)
 
 ;;;###autoload
@@ -2329,7 +2330,8 @@
 	  (while (and ignored-headers
 		      (re-search-forward ignored-headers nil t))
 	    (beginning-of-line)
-	    (if (looking-at rmail-nonignored-headers)
+	    (if (and rmail-nonignored-headers
+		     (looking-at rmail-nonignored-headers))
 		(forward-line 1)
 	      (delete-region (point)
 			     (save-excursion