]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix Rmail summary for more than 99,999 messages
authorEli Zaretskii <eliz@gnu.org>
Sat, 16 Jan 2021 18:18:32 +0000 (20:18 +0200)
committerEli Zaretskii <eliz@gnu.org>
Sat, 16 Jan 2021 18:18:32 +0000 (20:18 +0200)
* lisp/mail/rmailsum.el (rmail-summary-font-lock-keywords): Don't
assume there will be less than 100,000 messages in an mbox file.
(Bug#45912)

lisp/mail/rmailsum.el

index 60b67edf85a7aa8ba212b8a31618252572d7dd10..d29115a95701d4ea0c9e0f5f26f650ab9f45f8da 100644 (file)
@@ -51,10 +51,10 @@ Setting this option to nil might speed up the generation of summaries."
   :group 'rmail-summary)
 
 (defvar rmail-summary-font-lock-keywords
-  '(("^.....D.*" . font-lock-string-face)                      ; Deleted.
-    ("^.....-.*" . font-lock-type-face)                                ; Unread.
+  '(("^ *[0-9]+D.*" . font-lock-string-face)                   ; Deleted.
+    ("^ *[0-9]+-.*" . font-lock-type-face)                     ; Unread.
     ;; Neither of the below will be highlighted if either of the above are:
-    ("^.....[^D-] \\(......\\)" 1 font-lock-keyword-face)      ; Date.
+    ("^ *[0-9]+[^D-] \\(......\\)" 1 font-lock-keyword-face)   ; Date.
     ("{ \\([^\n}]+\\) }" 1 font-lock-comment-face))            ; Labels.
   "Additional expressions to highlight in Rmail Summary mode.")