IMAP now supports the nologin flag in the context and will refuse
authorDave West <davew@uncensored.citadel.org>
Thu, 17 Jul 2008 18:37:06 +0000 (18:37 +0000)
committerDave West <davew@uncensored.citadel.org>
Thu, 17 Jul 2008 18:37:06 +0000 (18:37 +0000)
connections if its set.

citadel/modules/imap/serv_imap.c

index 2a47b4e223c7247356912faa56f7792b4860c3ca..5c2e1589922805768cccbae88680f3a78f8d67ac 100644 (file)
@@ -498,6 +498,12 @@ void imap_greeting(void)
        IMAP->cached_rfc822_msgnum = (-1);
        IMAP->cached_rfc822_withbody = 0;
 
+       if (CC->nologin)
+       {
+               cprintf("* BYE; Server busy, try later\r\n");
+               CC->kill_me = 1;
+               return;
+       }
        cprintf("* OK [");
        imap_output_capability_string();
        cprintf("] %s IMAP4rev1 %s ready\r\n", config.c_fqdn, CITADEL);