From: Katsumi Yamaoka <yamaoka@jpl.org>
To: Andreas Schwab <schwab@suse.de>
Cc: 31651@debbugs.gnu.org
Subject: bug#31651: 26.1.50; message-forward-included-headers should contain "^$"
Date: Thu, 31 May 2018 08:30:37 +0900 [thread overview]
Message-ID: <b4mlgc0u3fm.fsf@jpl.org> (raw)
In-Reply-To: <b4m1sdtg7tq.fsf@jpl.org>
On Wed, 30 May 2018 09:56:11 +0200, Andreas Schwab wrote:
> I think this is a bug. The empty line is not a header line, so it
> should not be matched against.
Though I was going to apply the following first change, I came
to think you are right and committed the second one. Thanks.
1. Make `message-remove-ignored-headers' exclude header separator
when narrowing.
--- message.el~ 2018-01-12 03:53:45.394148600 +0000
+++ message.el 2018-05-30 22:49:55.198043700 +0000
@@ -7393,3 +7393,6 @@
(narrow-to-region (point)
- (or (search-forward "\n\n" nil t) (point)))
+ (if (search-forward "\n\n" nil t)
+ ;; Exclude header separator.
+ (1- (match-end 0))
+ (point)))
(when message-forward-ignored-headers
2. Make `message-remove-header' not remove things not looking
like header ("[!-9;-~]+:" comes from RFC2822 section 2.2).
--- message.el~ 2018-01-12 03:53:45.394148600 +0000
+++ message.el 2018-05-30 22:49:55.198043700 +0000
@@ -2433,3 +2433,5 @@
(if (if reverse
- (not (looking-at regexp))
+ (and (not (looking-at regexp))
+ ;; Don't remove things not looking like header.
+ (looking-at "[!-9;-~]+:"))
(looking-at regexp))
prev parent reply other threads:[~2018-05-30 23:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-30 3:07 bug#31651: 26.1.50; message-forward-included-headers should contain "^$" Katsumi Yamaoka
2018-05-30 7:56 ` Andreas Schwab
2018-05-30 23:30 ` Katsumi Yamaoka [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b4mlgc0u3fm.fsf@jpl.org \
--to=yamaoka@jpl.org \
--cc=31651@debbugs.gnu.org \
--cc=schwab@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).