emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: smtp crap


From: Michael Welsh Duggan
Subject: Re: smtp crap
Date: Sat, 08 Oct 2011 21:28:41 -0400
User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux)

Miles Bader <address@hidden> writes:

> Why does emacs _keep_ asking me if I want to "Set up Emacs for sending
> SMTP mail"?!
>
> My computer has a MTA, it works; if Emacs tries to send smtp directly,
> it very possibly _won't_ work[*].  So this question isn't just
> annoying, it's harmful.
>
> I kept answer "n" to this question, but just now I accidentally
> answered "y" -- and now only did that one piece of mail end up in the
> bit-bucket, but emacs now seems to be in a state where it thinks I
> want to use smtp -- it keeps asking me for an smtp server -- even
> though I've changed the variable (`send-mail-function') back to what I
> guess it should be (`sendmail-send-it').

I recently solved this problem for myself.  I was seeing the same
behavior.  The problem was this: sending mail called the function stored
in message-send-mail-function.  This variable is initialized in
message.el from send-mail-function, which defaults to
sendmail-query-once.  Once I answered "n" to the query, it changed
send-mail-function for sendmail-send-it via customize.  Unfortunately, I
use a separate custom file by setting custom-file in my .emacs.el.  At the
end of my .emacs.el, I load the file with (load custom-file).

What happens here is that send-mail-function is set to
sendmail-query-once, then my .emacs.el is read.  In my .emacs.el, I have a
(require 'message), which then initializes message-send-mail-function to
sendmail-query-once.  Then my .emacs.el loads my custom file, which sets
send-mail-function to sendmail-send-it.  Then, when I send mail, it
calls sendmail-query-once, as this is what message-send-mail-function is
set to.

I fixed this by loading my custom file before requiring message.el.
Your problem may be different, but if not, this experience of mine
might help.

-- 
Michael Welsh Duggan
(address@hidden)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]