aboutsummaryrefslogtreecommitdiffstats
path: root/fetchmail.h
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2021-08-27 19:22:34 +0200
committerMatthias Andree <matthias.andree@gmx.de>2021-08-27 19:50:07 +0200
commit74771392abf037d06751dd1f42f11248bfa6e8c2 (patch)
tree5d4ce03a5d86cc82b787f01a290ba2e440a544f6 /fetchmail.h
parentec8e9e35cafd2151c0e098d8e1c82475a0af347f (diff)
downloadfetchmail-74771392abf037d06751dd1f42f11248bfa6e8c2.tar.gz
fetchmail-74771392abf037d06751dd1f42f11248bfa6e8c2.tar.bz2
fetchmail-74771392abf037d06751dd1f42f11248bfa6e8c2.zip
struct method: introduce con-/destructors
These can be used before setting up or after closing down a socket for protocol-specific initialisiation or cleanup, and are required to cleanly fix up the IMAP-loses-protocol-version regression without too many temporary hacks in the code.
Diffstat (limited to 'fetchmail.h')
-rw-r--r--fetchmail.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fetchmail.h b/fetchmail.h
index d976f481..a1b77468 100644
--- a/fetchmail.h
+++ b/fetchmail.h
@@ -249,6 +249,8 @@ struct method /* describe methods for protocol state machine */
int (*logout_cmd)(int, struct query *);
/* logout command */
flag retry; /* can getrange poll for new messages? */
+ int (*construct)(struct query *); /* session setup before first command */
+ int (*destruct)(struct query *); /* cleanup after session */
};
enum badheader { BHREJECT = 0, BHACCEPT };