diff options
author | Fabian Groffen <grobian@gentoo.org> | 2019-11-11 08:34:49 +0100 |
---|---|---|
committer | Kevin McCarthy <kevin@8t8.us> | 2019-11-30 13:59:51 -0800 |
commit | 136ae0add512f21bc418f9e31a2f1b970ad1a490 (patch) | |
tree | 82797901e6688047b77fb05a6d4865db2e260cbb /mutt.h | |
parent | 1dd65e6beb0f1d211d63f936d92aecc792d2f72b (diff) |
imap: add support for COMPRESS=DEFLATE, RFC 4978
- added mutt_zstrm which allows wrapping an existing connection with
deflate/inflate (zlib compression)
- call mutt_zstrm_wrap_conn when setting up an IMAP connection if the
server supports COMPRESSION=DEFLATE and imap_deflate evaluates to yes
- add config quad-option imap_deflate enable/disable use of
(de)compression for IMAP connections, defaulting to yes
- add configure check for zlib, --with-zlib to detect if mutt_zstrm can
(or should) be built
Tested against a Dovecot IMAP server, observed easily 7x compression
rates on received data, and 5x on sent data for a normal session. Rates
can be observed when the connection is closed on debug level 4 and
higher.
Bug: https://gitlab.com/muttmua/mutt/issues/92
Diffstat (limited to 'mutt.h')
-rw-r--r-- | mutt.h | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -318,6 +318,9 @@ enum OPT_FORWEDIT, OPT_FCCATTACH, OPT_INCLUDE, +#if defined(USE_IMAP) && defined(USE_ZLIB) + OPT_IMAPDEFLATE, +#endif OPT_MFUPTO, OPT_MIMEFWD, OPT_MIMEFWDREST, @@ -444,6 +447,9 @@ enum OPTIMAPPEEK, OPTIMAPQRESYNC, OPTIMAPSERVERNOISE, +#ifdef USE_ZLIB + OPTIMAPDEFLATE, +#endif #endif #if defined(USE_SSL) # ifndef USE_SSL_GNUTLS |