Commit 08f0b0b9 authored by Lars Ingebrigtsen's avatar Lars Ingebrigtsen

Fold too-long headers in Message automatically

* lisp/gnus/message.el (message--fold-long-headers): Header lines
should be no longer than 79 characters before folding
(bug#33313).  Previous comment about 998 octets is about maximum
allowed header field length.
parent dfb5282f
......@@ -4643,11 +4643,11 @@ If you always want Gnus to send messages in one piece, set
(defun message--fold-long-headers ()
"Fold too-long header lines.
They should be no longer than 998 octets long."
Each line should be no more than 79 characters long."
(goto-char (point-min))
(while (not (eobp))
(when (and (looking-at "[^:]+:")
(> (- (line-end-position) (point)) 998))
(> (- (line-end-position) (point)) 79))
(mail-header-fold-field))
(forward-line 1)))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment