X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=citadel%2Fmodules%2Fimap%2Fserv_imap.c;h=31b3e5c96fb9cad2f3c677e48a3892064c2c7902;hb=84a0666848ccbea920f0bd398baf149c1a12ea74;hp=cd138b86d355d6cde0910581815e9d38843f367d;hpb=77ed8082379b4c2c9ebfc6d4b85656fc7f4782bf;p=citadel.git diff --git a/citadel/modules/imap/serv_imap.c b/citadel/modules/imap/serv_imap.c index cd138b86d..31b3e5c96 100644 --- a/citadel/modules/imap/serv_imap.c +++ b/citadel/modules/imap/serv_imap.c @@ -1596,14 +1596,17 @@ const char *CitadelServiceIMAPS="IMAPS"; */ CTDL_MODULE_INIT(imap) { - CtdlRegisterServiceHook(config.c_imap_port, - NULL, imap_greeting, imap_command_loop, NULL, CitadelServiceIMAP); + if (!threading) + { + CtdlRegisterServiceHook(config.c_imap_port, + NULL, imap_greeting, imap_command_loop, NULL, CitadelServiceIMAP); #ifdef HAVE_OPENSSL - CtdlRegisterServiceHook(config.c_imaps_port, - NULL, imaps_greeting, imap_command_loop, NULL, CitadelServiceIMAPS); + CtdlRegisterServiceHook(config.c_imaps_port, + NULL, imaps_greeting, imap_command_loop, NULL, CitadelServiceIMAPS); #endif - CtdlRegisterSessionHook(imap_cleanup_function, EVT_STOP); - + CtdlRegisterSessionHook(imap_cleanup_function, EVT_STOP); + } + /* return our Subversion id for the Log */ return "$Id$"; }