diff options
author | Eric S. Raymond <esr@thyrsus.com> | 1997-01-13 21:24:27 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 1997-01-13 21:24:27 +0000 |
commit | e644052b38ac03a5683f6ba48554dfb4cfe78c9c (patch) | |
tree | 69c0ae12e6b4edcc6766999455c0c821d5c2d446 /options.c | |
parent | 1a4bd3b6e4bd25b98a763decd9000b118483b2a8 (diff) | |
download | fetchmail-e644052b38ac03a5683f6ba48554dfb4cfe78c9c.tar.gz fetchmail-e644052b38ac03a5683f6ba48554dfb4cfe78c9c.tar.bz2 fetchmail-e644052b38ac03a5683f6ba48554dfb4cfe78c9c.zip |
Gather all server data into a restorable structure.
svn path=/trunk/; revision=754
Diffstat (limited to 'options.c')
-rw-r--r-- | options.c | 24 |
1 files changed, 12 insertions, 12 deletions
@@ -172,18 +172,18 @@ struct query *ctl; /* option record to be initialized */ case LA_PROTOCOL: /* XXX -- should probably use a table lookup here */ if (strcasecmp(optarg,"pop2") == 0) - ctl->protocol = P_POP2; + ctl->server.protocol = P_POP2; else if (strcasecmp(optarg,"pop3") == 0) - ctl->protocol = P_POP3; + ctl->server.protocol = P_POP3; else if (strcasecmp(optarg,"imap") == 0) - ctl->protocol = P_IMAP; + ctl->server.protocol = P_IMAP; else if (strcasecmp(optarg,"apop") == 0) - ctl->protocol = P_APOP; + ctl->server.protocol = P_APOP; else if (strcasecmp(optarg,"kpop") == 0) { - ctl->protocol = P_POP3; - ctl->port = KPOP_PORT; - ctl->authenticate = A_KERBEROS; + ctl->server.protocol = P_POP3; + ctl->server.port = KPOP_PORT; + ctl->server.authenticate = A_KERBEROS; } else { fprintf(stderr,"Invalid protocol `%s' specified.\n", optarg); @@ -192,14 +192,14 @@ struct query *ctl; /* option record to be initialized */ break; case 'P': case LA_PORT: - ctl->port = atoi(optarg); + ctl->server.port = atoi(optarg); break; case 'A': case LA_AUTHENTICATE: if (strcmp(optarg, "password") == 0) - ctl->authenticate = A_PASSWORD; + ctl->server.authenticate = A_PASSWORD; else if (strcmp(optarg, "kerberos") == 0) - ctl->authenticate = A_KERBEROS; + ctl->server.authenticate = A_KERBEROS; else { fprintf(stderr,"Invalid authentication `%s' specified.\n", optarg); errflag++; @@ -207,11 +207,11 @@ struct query *ctl; /* option record to be initialized */ break; case 't': case LA_TIMEOUT: - ctl->timeout = atoi(optarg); + ctl->server.timeout = atoi(optarg); break; case 'E': case LA_ENVELOPE: - ctl->envelope = xstrdup(optarg); + ctl->server.envelope = xstrdup(optarg); break; case 'u': |