Rewrite IMAP-Module to buffer its output
authorWilfried Goesgens <dothebart@citadel.org>
Sun, 7 Nov 2010 20:29:18 +0000 (21:29 +0100)
committerWilfried Goesgens <dothebart@citadel.org>
Sun, 7 Nov 2010 20:29:18 +0000 (21:29 +0100)
commit826932b012c26b5ef97a5bbf45acf10fca6acc60
tree2646db1a048eadac2a65f5b94c19b3684344e8a3
parenta1b7d9e895e73401161427363611b0160f51225f
Rewrite IMAP-Module to buffer its output

 - move defines from imap_tools.h into serv_imap.h
 - switch includes in sequence
 - we now have IMAP->Reply, which we write into, until IUnbuffer sends it to the client
 - IReply & IReplyPrintf do now send 'Params[0].Key BAD xxxxxx\r\n' to the client; this makes the code more compact.
 - IA* append stuff to the outbuffer that we want to send.
 - replace rumpelstilskin handler lookup by hashlist and central register calls.
 - replace if's in the sequence separating the handlers by their required pre-conditions by flags on the register call.

this should
 - (hopefully) fix some troubles with evolutions imap, which wouldn't like to read enough chunks until the line ends
 - speed up stuff like header fetching in huge lists, since we reduce the number of context switches here.
citadel/modules/imap/imap_acl.c
citadel/modules/imap/imap_fetch.c
citadel/modules/imap/imap_list.c
citadel/modules/imap/imap_metadata.c
citadel/modules/imap/imap_misc.c
citadel/modules/imap/imap_search.c
citadel/modules/imap/imap_store.c
citadel/modules/imap/imap_tools.c
citadel/modules/imap/imap_tools.h
citadel/modules/imap/serv_imap.c
citadel/modules/imap/serv_imap.h