* It is now possible to set a default poll interval with `set daemon'.
+* -U option to force UIDL use under POP3 (thanks, Ingmar Baumgart).
+
There are 249 people on the fetchmail-friends list.
------------------------------------------------------------------------------
DEFAULT(ctl->rewrite, TRUE);
DEFAULT(ctl->stripcr, (ctl->mda != (char *)NULL));
DEFAULT(ctl->server.dns, TRUE);
+ DEFAULT(ctl->server.uidl, FALSE);
#undef DEFAULT
/* plug in the semi-standard way of indicating a mail address */
printf(" (using port %d)", ctl->server.port);
else if (outlevel == O_VERBOSE)
printf(" (using default port)");
+ if (ctl->server.uidl)
+ printf(" (forcing UIDL use)");
putchar('.');
putchar('\n');
if (ctl->server.authenticate == A_KERBEROS)
char *envelope;
int skip;
int dns;
+ int uidl;
#ifdef linux
char *interface;
client machine and begin forwarding any items addressed to your client
machine in the server's queue of undelivered mail.
.TP
+.B \-U, --uidl
+Force UIDL use (effective only with POP3). Force client-side tracking
+of `newness' of messages. Use with `keep' to use a mailbox as a baby
+news drop for a group of users; if the mailbox is periodically purged,
+every member will get a chance to read the message.
+.TP
.B \-P, --port
The option permits you to specify a TCP/IP port to connect on.
This option will seldom be necessary as all the supported protocols have
#define LA_RCFILE 11
#define LA_IDFILE 12
#define LA_PROTOCOL 13
-#define LA_PORT 14
-#define LA_AUTHENTICATE 15
-#define LA_TIMEOUT 16
-#define LA_ENVELOPE 17
-#define LA_USERNAME 18
-#define LA_ALL 19
-#define LA_KILL 20
-#define LA_KEEP 21
-#define LA_FLUSH 22
-#define LA_NOREWRITE 23
-#define LA_LIMIT 24
-#define LA_REMOTEFILE 25
-#define LA_SMTPHOST 26
-#define LA_BATCHLIMIT 27
-#define LA_FETCHLIMIT 28
-#define LA_MDA 29
-#define LA_INTERFACE 30
-#define LA_MONITOR 31
-#define LA_YYDEBUG 32
-
-static char *shortoptions = "?Vcsvd:NqL:f:i:p:P:A:t:E:u:akKFnl:r:S:b:B:m:I:M:y";
+#define LA_UIDL 14
+#define LA_PORT 15
+#define LA_AUTHENTICATE 16
+#define LA_TIMEOUT 17
+#define LA_ENVELOPE 18
+#define LA_USERNAME 19
+#define LA_ALL 20
+#define LA_KILL 21
+#define LA_KEEP 22
+#define LA_FLUSH 23
+#define LA_NOREWRITE 24
+#define LA_LIMIT 25
+#define LA_REMOTEFILE 26
+#define LA_SMTPHOST 27
+#define LA_BATCHLIMIT 28
+#define LA_FETCHLIMIT 29
+#define LA_MDA 30
+#define LA_INTERFACE 31
+#define LA_MONITOR 32
+#define LA_YYDEBUG 33
+
+static char *shortoptions = "?Vcsvd:NqL:f:i:p:UP:A:t:E:u:akKFnl:r:S:b:B:m:I:M:y";
static struct option longoptions[] = {
{"help", no_argument, (int *) 0, LA_HELP },
{"version", no_argument, (int *) 0, LA_VERSION },
{"protocol", required_argument, (int *) 0, LA_PROTOCOL },
{"proto", required_argument, (int *) 0, LA_PROTOCOL },
+ {"uidl", no_argument, (int *) 0, LA_UIDL },
{"port", required_argument, (int *) 0, LA_PORT },
{"auth", required_argument, (int *) 0, LA_AUTHENTICATE},
{"timeout", required_argument, (int *) 0, LA_TIMEOUT },
errflag++;
}
break;
+ case 'U':
+ case LA_UIDL:
+ ctl->server.uidl = FLAG_TRUE;
+ break;
case 'P':
case LA_PORT:
ctl->server.port = atoi(optarg);
#endif
fputs(" -p, --protocol specify pop2, pop3, imap, apop, rpop, kpop, etrn\n", stderr);
+ fputs(" -U, --uidl force the use of UIDLs (pop3 only)\n", stderr);
fputs(" -P, --port TCP/IP service port to connect to\n",stderr);
fputs(" -A, --auth authentication type (password or kerberos)\n",stderr);
fputs(" -t, --timeout server nonresponse timeout\n",stderr);
{
char id [IDLEN+1];
- gen_send(sockfp,"LAST");
- ok = pop3_ok(sockfp, buf);
+ if (!ctl->server.uidl) {
+ gen_send(sockfp,"LAST");
+ ok = pop3_ok(sockfp, buf);
+ } else
+ ok = 1;
if (ok == 0)
{
if (sscanf(buf, "%d", &last) == 0)
rewrite { return REWRITE; }
stripcr { return STRIPCR; }
dns { return DNS; }
+uidl { return UIDL; }
limit { return LIMIT; }
%token <proto> PROTO
%token <sval> STRING
%token <number> NUMBER
-%token NO KEEP FLUSH FETCHALL REWRITE STRIPCR DNS PORT
+%token NO KEEP FLUSH FETCHALL REWRITE STRIPCR DNS PORT UIDL
%%
| FETCHALL {current.fetchall = FLAG_TRUE;}
| REWRITE {current.rewrite = FLAG_TRUE;}
| STRIPCR {current.stripcr = FLAG_TRUE;}
+ | UIDL {current.uidl = FLAG_TRUE;}
| NO KEEP {current.keep = FLAG_FALSE;}
| NO FLUSH {current.flush = FLAG_FALSE;}
| NO FETCHALL {current.fetchall = FLAG_FALSE;}
| NO REWRITE {current.rewrite = FLAG_FALSE;}
| NO STRIPCR {current.stripcr = FLAG_FALSE;}
+ | NO UIDL {current.uidl = FLAG_FALSE;}
| LIMIT NUMBER {current.limit = $2;}
| FETCHLIMIT NUMBER {current.fetchlimit = $2;}
# poll -- must be followed by a mailserver name
# skip -- must be followed by a mailserver name
# protocol (or proto) -- must be followed by a protocol ID
+# uidl
# port -- must be followed by a TCP/IP port number
# authenticate (or auth) -- must be followed by an authentication type
# timeout -- must be followed by a numeric timeout value