Gnus development mailing list
 help / color / mirror / Atom feed
From: Ted Stern <stern+gnus@cray.com>
Subject: Re: bug in message.el, message-forward-make-body-plain
Date: Wed, 01 Dec 2004 13:39:49 -0800	[thread overview]
Message-ID: <ycc1xe9zoii.fsf@monkeypuzzle.wc.cray.com> (raw)
In-Reply-To: <87y8ghyf39.fsf@orebokech.com>

[-- Attachment #1: Type: text/plain, Size: 2033 bytes --]

On 1 Dec 2004 at 11:48 PST, Romain Francoise wrote:
> The fix looks simple enough; the problem appears to be in this change:
>
> <URL: http://quimby.gnus.org/cgi-bin/cvsweb.cgi/gnus/lisp/message.el.diff?r1=6.377&r2=6.378>
>
> With the following ChangeLog entry:
>
> 2003-10-29  Simon Josefsson  <jas@extundo.com>
>
> 	* message.el (message-forward-make-body-plain): Remove ignored
> 	headers.  Tiny patch from Andre Srinivasan <andre@e2open.com>.
> 	(message-forward-make-body-plain): Fix ARG=1.
>
> The test is weird:
>
> (when (and (not current-prefix-arg)
>            message-forward-ignored-headers)
>
> how can current-prefix-arg be nil since you call this function from C-u
> C-c C-f?  Its value is '(4) here... unless I'm missing something.
>
> Index: message.el
> ===================================================================
> RCS file: /usr/local/cvsroot/gnus/lisp/message.el,v
> retrieving revision 7.63
> diff -u -r7.63 message.el
> --- message.el	26 Nov 2004 03:07:29 -0000	7.63
> +++ message.el	1 Dec 2004 19:46:41 -0000
> @@ -6257,8 +6263,7 @@
>         (buffer-string)))
>      (setq e (point))
>      (insert
> -    (when (and (not current-prefix-arg)
> -	       message-forward-ignored-headers)
> +    (when message-forward-ignored-headers
>        (save-restriction
>  	(narrow-to-region b e)
>  	(goto-char b)

Thanks Romain,

This patch works for me, but the offsets are wrong.  After making the change
manually I am able to advise gnus-summary-mail-forward correctly to do what I
want (remove unwanted headers when not forwarding as rfc822 MIME).

I did my own diff and am attaching it as inline MIME to avoid space problems.

Ted
-- 
 Ted Stern                                 Applications Group
 Cray Inc.                               office: 206-701-2182
 411 First Avenue South, Suite 600         cell: 206-383-1049
 Seattle, WA 98104-2860                     FAX: 206-701-2500

 Frango ut patefaciam -- I break that I may reveal
 (The Paleontological Society motto, equally apropos for debugging)


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: message.el patch for message-forward-make-body-plain bug --]
[-- Type: text/x-patch, Size: 606 bytes --]

Index: message.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/message.el,v
retrieving revision 7.63
diff -u -r7.63 message.el
--- message.el	26 Nov 2004 03:07:29 -0000	7.63
+++ message.el	1 Dec 2004 21:37:22 -0000
@@ -6258,8 +6258,7 @@
     (setq e (point))
     (insert
      "\n-------------------- End of forwarded message --------------------\n")
-    (when (and (not current-prefix-arg)
-	       message-forward-ignored-headers)
+    (when message-forward-ignored-headers
       (save-restriction
 	(narrow-to-region b e)
 	(goto-char b)

  reply	other threads:[~2004-12-01 21:39 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-30 20:08 Ted Stern
2004-12-01  8:19 ` Katsumi Yamaoka
2004-12-01 19:15   ` Ted Stern
2004-12-01 19:48   ` Romain Francoise
2004-12-01 21:39     ` Ted Stern [this message]
2004-12-01 21:56       ` Romain Francoise
2004-12-02  8:25         ` Katsumi Yamaoka
2004-12-02  9:09           ` Romain Francoise
2004-12-19 22:26     ` Kai Grossjohann
2004-12-20 18:06       ` Ted Stern

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=ycc1xe9zoii.fsf@monkeypuzzle.wc.cray.com \
    --to=stern+gnus@cray.com \
    /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).