🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.vm.bug
Article #8775

Re: vm-reply-include-text not working/vm-5.33/emacs-19.16

#8775
From: Basim Kadhim
Date: Tue, 13 Jul 1993 19:53
104 lines
4909 bytes
In article <9307072258.AA12243@redwood052.cray.com> mack@redwood.cray.com (Dan Mack) writes:

   Software/System:

	   emacs-19.16
	   vm-5.33

   Synopsis:

	   vm-inlcuded-text-prefix and vm-included-text-attribution-format
	   aren't being "honored" under vm-5.33 when using emacs-19.16.

	   Here is what I claim to be a bug:

	     o The included text is indented, but the prefix is absent.
	     o The attribution format stuff is also missing "James Doe writes:"
	     o The extra header, X-VM-v5-Data stuff is included, adding to the
	       already confusing message.


This bug has been annoying me ever since I started using Emacs-19 to the point
that I ran a window with Emacs-18 just to read my mail.  Well, I finally
caved in and went hunting for the bug.  The problem is that under Emacs-19,
the variable mail-yank-hooks defaults to mail-indent-citation rather than
nil as it was in Emacs-18.  This difference exposed a bug in the VM code.
The quick and dirty solution is to set mail-indent-citation back to nil
and everything works like it should.  Since there was actually a bug in the
VM code, though, I decided to try and fix it.  Replying has actually always
worked differently than it was documented.  According to the documentation,
all of the visible headers (as defined be vm-visible-headers) are supposed
to be included with the included text.  I don't like this and this wasn't
the previous behavior, so my fix makes it work like it did before and 
changes the documentation of the function.  Without further ado, here is
the fix:

-------------------------------------------------------------------------------
*** vm-reply.el	Tue Jul 13 13:36:03 1993
--- vm-reply.el.orig	Wed Oct 16 12:47:27 1991
***************
*** 121,127 ****
  	    (re-search-forward (concat "^" mail-header-separator "$") nil 0)
  	    (forward-char 1)
  	    (while mlist
! 	      (vm-yank-message (car mlist) t)
  	      (goto-char (point-max))
  	      (setq mlist (cdr mlist))))))))
  
--- 121,127 ----
  	    (re-search-forward (concat "^" mail-header-separator "$") nil 0)
  	    (forward-char 1)
  	    (while mlist
! 	      (vm-yank-message (car mlist))
  	      (goto-char (point-max))
  	      (setq mlist (cdr mlist))))))))
  
***************
*** 198,204 ****
  
  Prefix arg means to ignore mail-yank-hooks, don't set the mark, prepend the
  value of vm-included-text-prefix to every yanked line, and don't yank any
! headers."
    (interactive
     (list
     ;; What we really want for the first argument is a message struct,
--- 198,204 ----
  
  Prefix arg means to ignore mail-yank-hooks, don't set the mark, prepend the
  value of vm-included-text-prefix to every yanked line, and don't yank any
! headers other than those specified in vm-visible-headers/vm-invisible-headers."
    (interactive
     (list
     ;; What we really want for the first argument is a message struct,
***************
*** 233,242 ****
  	(set-buffer (marker-buffer (vm-start-of message)))
  	(save-restriction
  	  (widen)
! 	  (append-to-buffer b (vm-text-of message)
  			    (vm-text-end-of message))
  	  (setq end (vm-marker (+ start (- (vm-text-end-of message)
! 					   (vm-text-of message))) b))))
        (if prefix
  	  (save-excursion
  	    (while (and (< (point) end) (re-search-forward "^" end t))
--- 233,246 ----
  	(set-buffer (marker-buffer (vm-start-of message)))
  	(save-restriction
  	  (widen)
! 	  (append-to-buffer b (if prefix
! 				  (vm-vheaders-of message)
! 				(vm-start-of message))
  			    (vm-text-end-of message))
  	  (setq end (vm-marker (+ start (- (vm-text-end-of message)
! 					   (if prefix
! 					       (vm-vheaders-of message)
! 					     (vm-start-of message)))) b))))
        (if prefix
  	  (save-excursion
  	    (while (and (< (point) end) (re-search-forward "^" end t))
-------------------------------------------------------------------------------

--
Basim Kadhim					kadhim@cs.colorado.edu
University of Colorado, Boulder
Technical Details
Message-ID: <KADHIM.93Jul13135357@riker.cs.colorado.edu>
Path: arc1-ca.pugleaf.net!gmd.de!xlink.net!howland.reston.ans.net!agate!boulder!news.colorado.edu!kadhim
References: <9307072258.AA12243@redwood052.cray.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f6829,e6a65eaeb140bdd6
X-Google-Attributes: gidf6829,public
X-Google-ArrivalTime: 1993-07-13 13:14:49 PST
Newsgroups: gnu.emacs.vm.bug
Path: arc1-ca.pugleaf.net!gmd.de!xlink.net!howland.reston.ans.net!agate!boulder!news.colorado.edu!kadhim
From: kadhim@riker.cs.colorado.edu (Basim Kadhim)
Subject: Re: vm-reply-include-text not working/vm-5.33/emacs-19.16
In-Reply-To: mack@redwood.cray.com's message of Wed, 7 Jul 1993 17:58:56 CDT
Message-ID: <KADHIM.93Jul13135357@riker.cs.colorado.edu>
Sender: news@colorado.edu (The Daily Planet)
Nntp-Posting-Host: riker.cs.colorado.edu
Reply-To: kadhim@cs.colorado.edu
Organization: Dept. of Computer Science, University of Colorado, Boulder
References: <9307072258.AA12243@redwood052.cray.com>
Date: 13 Jul 1993 19:53:57 GMT
Lines: 104