Gnus development mailing list
 help / color / mirror / Atom feed
From: Russ Allbery <eagle@eyrie.org>
To: ding@gnus.org
Subject: Re: mail-header-separator starting with whitespace fails
Date: Fri, 16 May 2014 16:35:14 -0700	[thread overview]
Message-ID: <8738g9mh59.fsf@windlord.stanford.edu> (raw)
In-Reply-To: <b4mfvkdb399.fsf@jpl.org> (Katsumi Yamaoka's message of "Wed, 14 May 2014 09:41:38 +0900")

Katsumi Yamaoka <yamaoka@jpl.org> writes:
> On Tue, 13 May 2014 09:31:04 -0700, Russ Allbery wrote:

>> (setq mail-header-separator (concat (make-string 39 ? ) "."))

> I tried this, confirmed it causes a mail corruption, and found
> at least one cause.  Could you try replacing the function definition
> of `rfc822-goto-eoh' with this?  (I.e., eval this form?)

> (defun rfc822-goto-eoh ()
>   "If the buffer starts with a mail header, move point to the header's end.
> Otherwise, moves to `point-min'.
> The end of the header is the start of the next line, if there is one,
> else the end of the last line.  This function obeys RFC822."
>   (goto-char (point-min))
>   (when (re-search-forward
> 	 (concat "^" (regexp-quote mail-header-separator) "\n\\|"
> 		 "^\\([:\n]\\|[^: \t\n]+[ \t\n]\\)")
> 	 nil 'move)
>     (goto-char (match-beginning 0))))

> This function is used by `smtpmail-send-it' by way of
> `mail-sendmail-undelimit-header' to delete the separator, but
> the original one doesn't respect `mail-header-separator'.

Sorry about the delay in verifying this.  That change does indeed fix my
problem.  Thank you!

> But I'm not quite sure that it is a cause of your problem, since
> those functions seem not to have been modified for years.  Didn't
> you use a separator that does not begin with a SPC, like this?

> .                                       .

No, the mail-header-separator setting I was using had been unchanged since
I started using Gnus back in 1994.

I was previously using the Gnus included in Emacs 23.4.  Something must
have changed from that version to Emacs 24.3 that caused this corruption,
although I'm not sure what.

-- 
Russ Allbery (eagle@eyrie.org)              <http://www.eyrie.org/~eagle/>



  reply	other threads:[~2014-05-16 23:35 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-13 16:31 Russ Allbery
2014-05-14  0:41 ` Katsumi Yamaoka
2014-05-16 23:35   ` Russ Allbery [this message]
2015-01-28  5:49   ` Lars Ingebrigtsen
2015-01-28  8:33     ` Katsumi Yamaoka
2015-01-29  1:47       ` Lars Ingebrigtsen
2015-01-29  2:31         ` Katsumi Yamaoka

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8738g9mh59.fsf@windlord.stanford.edu \
    --to=eagle@eyrie.org \
    --cc=ding@gnus.org \
    /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.
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 NNTP newsgroup(s).