aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS5
-rw-r--r--driver.c6
-rw-r--r--fetchmail.c9
-rw-r--r--options.c4
-rw-r--r--rcfile_y.y4
5 files changed, 19 insertions, 9 deletions
diff --git a/NEWS b/NEWS
index 8634f691..bbcd1714 100644
--- a/NEWS
+++ b/NEWS
@@ -16,12 +16,13 @@ fetchmail-4.3.1 ()
* Fixed a bad interaction between --limit and the repoll feature.
* = is now optional in global options.
* Code for parsing Received headers now strips out RFC822 routes.
-* Fixed processing of -S argument so giving a comma-separated list works.
+* Fixed processing of -S/-r arguments so giving a comma-separated list works.
+* Don't query for the fetchmail host machine by default in ETRN mode.
* Added --invisible option. Note: you can now either make fetchmail generate
a Received header (the default) *or* spoof your listener into thinking
fetchmail connected from the mailserver machine, *but not both*.
-There are 277 people on fetchmail-friends and 20 on fetchmail-announce.
+There are 272 people on fetchmail-friends and 36 on fetchmail-announce.
------------------------------------------------------------------------------
fetchmail-4.3.0 (Mon Oct 6 16:44:38 EDT 1997)
diff --git a/driver.c b/driver.c
index e1d52f21..756ab2b1 100644
--- a/driver.c
+++ b/driver.c
@@ -420,7 +420,11 @@ static int smtp_open(struct query *ctl)
errno = 0;
- /* run down the SMTP hunt list looking for a server that's up */
+ /*
+ * Run down the SMTP hunt list looking for a server that's up.
+ * Use both explicit hunt entries (value TRUE) and implicit
+ * (default) ones (value FALSE).
+ */
for (idp = ctl->smtphunt; idp; idp = idp->next)
{
ctl->smtphost = idp->id; /* remember last host tried. */
diff --git a/fetchmail.c b/fetchmail.c
index 4e346a77..f70d2d71 100644
--- a/fetchmail.c
+++ b/fetchmail.c
@@ -565,7 +565,7 @@ static int load_params(int argc, char **argv, int optind)
def_opts.server.protocol = P_AUTO;
def_opts.server.timeout = CLIENT_TIMEOUT;
def_opts.remotename = user;
- save_str(&def_opts.smtphunt, TRUE, fetchmailhost);
+ save_str(&def_opts.smtphunt, FALSE, fetchmailhost);
save_str(&def_opts.smtphunt, FALSE, "localhost");
def_opts.expunge = 1;
@@ -991,7 +991,12 @@ void dump_params (struct query *ctl)
printf(" Messages will be SMTP-forwarded to:");
for (idp = ctl->smtphunt; idp; idp = idp->next)
- printf(" %s", idp->id);
+ if (ctl->server.protocol != P_ETRN || idp->val.num)
+ {
+ printf(" %s", idp->id);
+ if (!idp->val.num)
+ printf(" (default)");
+ }
printf("\n");
}
if (ctl->preconnect)
diff --git a/options.c b/options.c
index 11d4cdef..f2432ed3 100644
--- a/options.c
+++ b/options.c
@@ -285,7 +285,7 @@ struct query *ctl; /* option record to be initialized */
strcpy(buf, optarg);
cp = strtok(buf, ",");
do {
- save_str(&ctl->mailboxes, -1, optarg);
+ save_str(&ctl->mailboxes, -1, cp);
} while
((cp = strtok((char *)NULL, ",")));
break;
@@ -294,7 +294,7 @@ struct query *ctl; /* option record to be initialized */
strcpy(buf, optarg);
cp = strtok(buf, ",");
do {
- save_str(&ctl->smtphunt, -1, cp);
+ save_str(&ctl->smtphunt, TRUE, cp);
} while
((cp = strtok((char *)NULL, ",")));
ocount++;
diff --git a/rcfile_y.y b/rcfile_y.y
index 3184a24c..213caae5 100644
--- a/rcfile_y.y
+++ b/rcfile_y.y
@@ -415,9 +415,9 @@ static void record_current(void)
FLAG_FORCE(remotename);
FLAG_FORCE(password);
if (cmd_opts.mailboxes)
- save_str(&current.mailboxes, -1, cmd_opts.mailboxes->id);
+ current.mailboxes = cmd_opts.mailboxes;
if (cmd_opts.smtphunt)
- save_str(&current.smtphunt, -1, cmd_opts.smtphunt->id);
+ current.smtphunt = cmd_opts.smtphunt;
FLAG_FORCE(mda);
FLAG_FORCE(preconnect);
FLAG_FORCE(postconnect);