Commit a34804da authored by Francesco Potortì's avatar Francesco Potortì

(rmail-forward-separator-regex): New custom variable.

(unforward-rmail-message): Use it.
parent e35b383a
......@@ -36,6 +36,14 @@
"\^_\^L\n0, unseen,,\n*** EOOH ***\n"
"String for separating messages in an rmail file.")
(defcustom rmail-forward-separator-regex
"*Regexp to match the string that introduces forwarded messages.
This is not a header, but a string contained in the body of the message.
You may need to customise it for local needs."
:type 'regexp
:group 'rmail-headers)
(defconst rmail-digest-methods
......@@ -231,8 +239,7 @@ following the containing message."
(forwarded-from (mail-fetch-field "From"))
(forwarded-date (mail-fetch-field "Date"))
beg end prefix forward-msg)
(cond ((re-search-forward
"^----.*\\([Ff]orwarded\\|[Oo]riginal\\).*[Mm]essage" nil t)
(cond ((re-search-forward rmail-forward-separator-regex nil t)
(forward-line 1)
(skip-chars-forward "\n")
(setq beg (point))
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