diff options
author | Charles Longeau <chl@cvs.openbsd.org> | 2012-08-25 23:35:10 +0000 |
---|---|---|
committer | Charles Longeau <chl@cvs.openbsd.org> | 2012-08-25 23:35:10 +0000 |
commit | 04b0d16fcd5086e7220b1bcb4d14c77855a23238 (patch) | |
tree | 9b78accae290b06eb1abb504924b363bd0a6d4e3 /usr.sbin/smtpd/smtpd.c | |
parent | f306d139dbf080f0221fe7bae15fed27738ebd01 (diff) |
Add compress_backend, allowing compression of messages and envelopes in the queue.
To use it, just add "queue compress" in smtpd.conf. For now, only zlib is used.
lots of feedback from eric@ and gilles@
ok eric@ gilles@
Diffstat (limited to 'usr.sbin/smtpd/smtpd.c')
-rw-r--r-- | usr.sbin/smtpd/smtpd.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/usr.sbin/smtpd/smtpd.c b/usr.sbin/smtpd/smtpd.c index 6ff6dd273b5..ac2e94d4d9d 100644 --- a/usr.sbin/smtpd/smtpd.c +++ b/usr.sbin/smtpd/smtpd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smtpd.c,v 1.163 2012/08/25 15:39:11 gilles Exp $ */ +/* $OpenBSD: smtpd.c,v 1.164 2012/08/25 23:35:09 chl Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@openbsd.org> @@ -575,6 +575,14 @@ main(int argc, char *argv[]) if (env->sc_stat == NULL) errx(1, "could not find stat backend \"%s\"", backend_stat); + if (env->sc_queue_compress_algo) { + env->sc_compress = + compress_backend_lookup(env->sc_queue_compress_algo); + if (env->sc_queue == NULL) + errx(1, "could not find queue compress backend \"%s\"", + env->sc_queue_compress_algo); + } + log_init(debug); log_verbose(verbose); |