Add $smtp_pass (closes #2116)
authorBrendan Cully <brendan@kublai.com>
Wed, 11 Apr 2007 20:40:10 +0000 (13:40 -0700)
committerBrendan Cully <brendan@kublai.com>
Wed, 11 Apr 2007 20:40:10 +0000 (13:40 -0700)
ChangeLog
account.c
globals.h
init.h

index 5f20190a09aa8bbb1952c013a708f47420e8ed79..660921db0e09f948d1cfee1bac4e8e1977250484 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,10 @@
-2007-04-11 07:37 -0700  Brendan Cully  <brendan@kublai.com>  (29faa739ed01)
+2007-04-11 12:53 -0700  Brendan Cully  <brendan@kublai.com>  (cdac16f99c5f)
+
+       * doc/Makefile.am: Explicit -j1 breaks some versions of make (see
+       #2538)
+
+       * imap/util.c: Make imap_hcache_open robust against missing
+       idata->ctx
 
        * imap/util.c: Do not attempt to parse idata->ctx->path if an explicit
        path is given
index 99951e25d1e6763e30be91b4cf2f0720c3802def..ca65754d5daf4e2ddbad886e0cda2274ae0499bb 100644 (file)
--- a/account.c
+++ b/account.c
@@ -213,6 +213,10 @@ int mutt_account_getpass (ACCOUNT* account)
 #ifdef USE_POP
   else if ((account->type == M_ACCT_TYPE_POP) && PopPass)
     strfcpy (account->pass, PopPass, sizeof (account->pass));
+#endif
+#ifdef USE_SMTP
+  else if ((account->type == M_ACCT_TYPE_SMTP) && SmtpPass)
+    strfcpy (account->pass, SmtpPass, sizeof (account->pass));
 #endif
   else
   {
index c32ec828968cd674e23087486c48dd07c6f71a71..15c0d140423dfba10ec5e66d02fcac56284fb905 100644 (file)
--- a/globals.h
+++ b/globals.h
@@ -118,8 +118,9 @@ WHERE char *Shell;
 WHERE char *Signature;
 WHERE char *SimpleSearch;
 #if USE_SMTP
-WHERE char *SmtpUrl INITVAL (NULL);
 WHERE char *SmtpAuthenticators INITVAL (NULL);
+WHERE char *SmtpPass INITVAL (NULL);
+WHERE char *SmtpUrl INITVAL (NULL);
 #endif /* USE_SMTP */
 WHERE char *Spoolfile;
 WHERE char *SpamSep;
diff --git a/init.h b/init.h
index 0801cd1aaac0f94bb0ad63c5435883926eee3ae9..07e96721efc000a05d6653b63fa25213385b7504 100644 (file)
--- a/init.h
+++ b/init.h
@@ -2559,17 +2559,6 @@ struct option_t MuttVars[] = {
   ** a value of zero for this option suppresses the pause.
   */
 #ifdef USE_SMTP
-  { "smtp_url",                DT_STR, R_NONE, UL &SmtpUrl, UL 0 },
-  /*
-  ** .pp
-  ** Defines the SMTP ``smart'' host where sent messages should relayed for
-  ** delivery. This should take the form of an SMTP URL, eg:
-  ** .pp
-  **   smtp[s]://[user[:pass]@]host[:port]/
-  ** .pp
-  ** Setting this variable overrides the value of the ``$$sendmail''
-  ** variable.
-  */
 # ifdef USE_SASL
   { "smtp_authenticators", DT_STR, R_NONE, UL &SmtpAuthenticators, UL 0 },
   /*
@@ -2585,6 +2574,27 @@ struct option_t MuttVars[] = {
    ** Example: set smtp_authenticators="digest-md5:cram-md5"
    */
 # endif /* USE_SASL */
+  { "smtp_pass",       DT_STR,  R_NONE, UL &SmtpPass, UL 0 },
+  /*
+  ** .pp
+  ** Specifies the password for your SMTP account.  If \fIunset\fP, Mutt will
+  ** prompt you for your password when you first send mail via SMTP.
+  ** See ``$smtp_url'' to configure mutt to send mail via SMTP.
+  ** \fBWarning\fP: you should only use this option when you are on a
+  ** fairly secure machine, because the superuser can read your muttrc even
+  ** if you are the only one who can read the file.
+  */
+  { "smtp_url",                DT_STR, R_NONE, UL &SmtpUrl, UL 0 },
+  /*
+  ** .pp
+  ** Defines the SMTP ``smart'' host where sent messages should relayed for
+  ** delivery. This should take the form of an SMTP URL, eg:
+  ** .pp
+  **   smtp[s]://[user[:pass]@]host[:port]/
+  ** .pp
+  ** Setting this variable overrides the value of the ``$$sendmail''
+  ** variable.
+  */
 #endif /* USE_SMTP */
   { "sort",            DT_SORT, R_INDEX|R_RESORT, UL &Sort, SORT_DATE },
   /*