aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fetchmail.c10
-rw-r--r--rcfile_y.y1
2 files changed, 10 insertions, 1 deletions
diff --git a/fetchmail.c b/fetchmail.c
index a3a734be..ebb2b899 100644
--- a/fetchmail.c
+++ b/fetchmail.c
@@ -533,7 +533,6 @@ static int load_params(int argc, char **argv, int optind)
}
/* similarly, compute server leaders for queries */
- ctl->aka = (struct idlist *)NULL;
for (mp = querylist; mp && mp != ctl; mp = mp->next)
if (strcmp(mp->servername, ctl->servername) == 0)
{
@@ -676,6 +675,15 @@ void dump_params (struct query *ctl)
if (ctl->canonical_name)
printf(" Canonical DNS name of server is %s.\n", ctl->canonical_name);
#endif /* HAVE_GETHOSTBYNAME */
+ if (ctl->aka)
+ {
+ struct idlist *idp;
+
+ printf(" Predeclared mailserver aliases:");
+ for (idp = ctl->aka; idp; idp = idp->next)
+ printf(" %s", idp->id);
+ putchar('\n');
+ }
if (ctl->skip || outlevel == O_VERBOSE)
printf(" This host will%s be queried when no host is specified.\n",
ctl->skip ? " not" : "");
diff --git a/rcfile_y.y b/rcfile_y.y
index 075c85a7..d22efa44 100644
--- a/rcfile_y.y
+++ b/rcfile_y.y
@@ -329,6 +329,7 @@ void optmerge(struct query *h2, struct query *h1)
/* merge two options records; empty fields in h2 are filled in from h1 */
{
append_uid_list(&h2->localnames, &h1->localnames);
+ append_uid_list(&h2->aka, &h1->aka);
#define STR_MERGE(fld, len) if (*(h2->fld) == '\0') strcpy(h2->fld, h1->fld)
STR_MERGE(remotename, USERNAMELEN);