aboutsummaryrefslogtreecommitdiffstats
path: root/fetchmail.h
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>1998-02-17 22:58:54 +0000
committerEric S. Raymond <esr@thyrsus.com>1998-02-17 22:58:54 +0000
commit38528f8329458e9faf675677bc7a2e4524af3aa4 (patch)
tree0508254c0a10dd52d2773e36b648071ab6258192 /fetchmail.h
parent2087cffd2b5bb197d12c2195ad1c054797abfdd1 (diff)
downloadfetchmail-38528f8329458e9faf675677bc7a2e4524af3aa4.tar.gz
fetchmail-38528f8329458e9faf675677bc7a2e4524af3aa4.tar.bz2
fetchmail-38528f8329458e9faf675677bc7a2e4524af3aa4.zip
Fix bad UID/fetchlimit interaction.
svn path=/trunk/; revision=1645
Diffstat (limited to 'fetchmail.h')
-rw-r--r--fetchmail.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/fetchmail.h b/fetchmail.h
index 50ce5640..3347889f 100644
--- a/fetchmail.h
+++ b/fetchmail.h
@@ -159,10 +159,6 @@ struct query
int batchlimit; /* max # msgs to pass in single SMTP session */
int expunge; /* max # msgs to pass between expunges */
- /* unseen, previous state of mailbox (initially from .fetchids) */
-#define UID_KEPT 0 /* this was remembered from a previous run */
-#define UID_DELETED -1 /* this message has been deleted */
-#define UID_EXPUNGED -2 /* this message has been expunged */
struct idlist *oldsaved, *newsaved;
/* internal use */
@@ -175,6 +171,17 @@ struct query
};
/*
+ * UID-index information. If the sign bit is on, this means the
+ * message UID has been seen or expunged and should be written
+ * out to .fetchids at end of run.
+ */
+#define UID_KEPT 0 /* remembered from a previous run */
+#define UID_DELETED INT_MIN /* this message has been deleted */
+#define UID_EXPUNGED INT_MAX /* this message has been expunged */
+#define SAVE_UID(n) ((n) < 0) /* must this UID be saved? */
+#define MARK_SEEN(n) n *= -1 /* mark a UID seen */
+
+/*
* Numeric option handling. Numeric option value of zero actually means
* it's unspecified. Value less than zero is zero.
*/