* [patch] Use user-mail-address as set by posting-styles
@ 1999-11-19 15:01 Rupa Schomaker (list)
1999-12-01 18:49 ` Lars Magne Ingebrigtsen
0 siblings, 1 reply; 4+ messages in thread
From: Rupa Schomaker (list) @ 1999-11-19 15:01 UTC (permalink / raw)
[-- Attachment #1: Type: text/plain, Size: 700 bytes --]
Attached is a patch that uses the user-mail-address (as set from
posting-styles) as an argument to senmdail -f. This ensures that the
envelope matches the From: which is preferable in all cases for me.
Mail list managers, funky mail programs (like outlook), and mail
gateways (notes<-->smtp) seem to place more trust in the envelope than
the From: header.
Lars, I noticed that message-generate-new-buffer-clone-locals takes an
optional second argument according to the documentation. However, the
actual code doesn't work that way -- the actual argument is ignored.
This isn't used much so it probably isn't a big deal, but maybe the
arg list should be modified to reflect the real behavior.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Use user-mail-address from posting-styles --]
[-- Type: text/x-patch, Size: 1992 bytes --]
Index: gnus-msg.el
===================================================================
RCS file: /home/cvs/cvsroot/elisp/pgnus/lisp/gnus-msg.el,v
retrieving revision 1.1.1.2
diff -u -r1.1.1.2 gnus-msg.el
--- gnus-msg.el 1999/07/20 18:20:36 1.1.1.2
+++ gnus-msg.el 1999/11/18 20:10:57
@@ -1192,6 +1192,8 @@
(when (or name address)
(add-hook 'message-setup-hook
`(lambda ()
+ (set (make-local-variable 'user-mail-address)
+ ,(or (cdr address) user-mail-address))
(let ((user-full-name ,(or (cdr name) user-full-name))
(user-mail-address
,(or (cdr address) user-mail-address)))
Index: message.el
===================================================================
RCS file: /home/cvs/cvsroot/elisp/pgnus/lisp/message.el,v
retrieving revision 1.1.1.4
diff -u -r1.1.1.4 message.el
--- message.el 1999/09/03 18:17:37 1.1.1.4
+++ message.el 1999/11/18 21:03:20
@@ -2130,7 +2130,7 @@
(defun message-send-mail-with-sendmail ()
"Send off the prepared buffer with sendmail."
(let ((errbuf (if message-interactive
- (generate-new-buffer " sendmail errors")
+ (message-generate-new-buffer-clone-locals " sendmail errors")
0))
resend-to-addresses delimline)
(let ((case-fold-search t))
@@ -2167,7 +2167,11 @@
;; But some systems are more broken with -f, so
;; we'll let users override this.
(if (null message-sendmail-f-is-evil)
- (list "-f" (user-login-name)))
+ (list "-f"
+ (if (null user-mail-address)
+ (user-login-name)
+ (user-mail-address))
+ ))
;; These mean "report errors by mail"
;; and "deliver in background".
(if (null message-interactive) '("-oem" "-odb"))
@@ -4088,7 +4092,7 @@
(let ((locals (save-excursion
(set-buffer buffer)
(buffer-local-variables)))
- (regexp "^gnus\\|^nn\\|^message"))
+ (regexp "^gnus\\|^nn\\|^message\\|^user-mail-address"))
(mapcar
(lambda (local)
(when (and (consp local)
[-- Attachment #3: Type: text/plain, Size: 81 bytes --]
--
Rupa (rupa@rupa.com for normal email)
Please don't email duplicate replies.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [patch] Use user-mail-address as set by posting-styles
1999-11-19 15:01 [patch] Use user-mail-address as set by posting-styles Rupa Schomaker (list)
@ 1999-12-01 18:49 ` Lars Magne Ingebrigtsen
1999-12-02 21:56 ` Raymond Scholz
0 siblings, 1 reply; 4+ messages in thread
From: Lars Magne Ingebrigtsen @ 1999-12-01 18:49 UTC (permalink / raw)
"Rupa Schomaker (list)" <rupa-list@rupa.com> writes:
> Attached is a patch that uses the user-mail-address (as set from
> posting-styles) as an argument to senmdail -f. This ensures that the
> envelope matches the From: which is preferable in all cases for me.
Thanks for the patch; I've applied it to Gnus v5.8.0.
> Lars, I noticed that message-generate-new-buffer-clone-locals takes an
> optional second argument according to the documentation. However, the
> actual code doesn't work that way -- the actual argument is ignored.
> This isn't used much so it probably isn't a big deal, but maybe the
> arg list should be modified to reflect the real behavior.
I've now fixed the code instead.
--
(domestic pets only, the antidote for overdose, milk.)
larsi@gnus.org * Lars Magne Ingebrigtsen
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [patch] Use user-mail-address as set by posting-styles
1999-12-01 18:49 ` Lars Magne Ingebrigtsen
@ 1999-12-02 21:56 ` Raymond Scholz
1999-12-03 0:22 ` Lars Magne Ingebrigtsen
0 siblings, 1 reply; 4+ messages in thread
From: Raymond Scholz @ 1999-12-02 21:56 UTC (permalink / raw)
Lars Magne Ingebrigtsen <larsi@gnus.org> writes:
> "Rupa Schomaker (list)" <rupa-list@rupa.com> writes:
>
> > Attached is a patch that uses the user-mail-address (as set from
> > posting-styles) as an argument to senmdail -f. This ensures that the
> > envelope matches the From: which is preferable in all cases for me.
>
> Thanks for the patch; I've applied it to Gnus v5.8.0.
Hmmm, but not preferable for me. Can I force the old behaviour
instead?
I'd like sendmail to do the "envelope thing" itself. My SMTP server
(GMX) requires an envelope matching my account there (rscholz@gmx.de)
but I still want my old From: header? Possible?
Cheers,
Ray
--
Raymond Scholz -*- rscholz@tzi.de -*- http://www.tzi.de/~rscholz/
FB 3 Informatik, Universität Bremen -*- PGP key available via WWW
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~1999-12-03 0:22 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-11-19 15:01 [patch] Use user-mail-address as set by posting-styles Rupa Schomaker (list)
1999-12-01 18:49 ` Lars Magne Ingebrigtsen
1999-12-02 21:56 ` Raymond Scholz
1999-12-03 0:22 ` Lars Magne Ingebrigtsen
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).