[Dovecot] zlib Plugin Dovecot 2.0
Timo Sirainen
tss at iki.fi
Fri Apr 16 18:34:54 EEST 2010
On Fri, 2010-04-16 at 09:55 -0300, Alex Baule wrote:
> Part of reading I already migrated, only that the piece of writing (the new
> part in the plugin) I need to understand some things about the operation in
> order to migrate and redo the same functions with the separation of body /
> header
So you also want to add support for the split operating directly during
saving new mails?
I guess you can copy&paste most of the code from zlib-plugin.c and just
implement a new ostream. ostream-bzlib.c should give a good example. You
just need to implement:
- sendv(): this works similar to writev() syscall. Here you need to
keep read the input bytes and track when the message header ends and
write to different files before/after that.
- flush(): If you do any buffering, flush it here.
That's about it. Much simpler than istreams!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20100416/9e36a0b3/attachment.bin
More information about the dovecot
mailing list