]> code.citadel.org Git - citadel.git/blobdiff - citadel/serv_imap.c
* Added a skeleton IMAP "SEARCH" command (based on the FETCH logic)
[citadel.git] / citadel / serv_imap.c
index 3b544fd29eb883b622132b6a0a48a24b28499513..62a3ba95b186cc3ed0c3052416938a039e0843cc 100644 (file)
@@ -41,6 +41,7 @@
 #include "serv_imap.h"
 #include "imap_tools.h"
 #include "imap_fetch.h"
+#include "imap_search.h"
 
 
 long SYM_IMAP;
@@ -480,6 +481,15 @@ void imap_command_loop(void) {
                imap_uidfetch(num_parms, parms);
        }
 
+       else if (!strcasecmp(parms[1], "SEARCH")) {
+               imap_search(num_parms, parms);
+       }
+
+       else if ( (!strcasecmp(parms[1], "UID"))
+               && (!strcasecmp(parms[2], "SEARCH")) ) {
+               imap_uidsearch(num_parms, parms);
+       }
+
        else if (!strcasecmp(parms[1], "CLOSE")) {
                imap_close(num_parms, parms);
        }