#include <stdio.h>
#include <ctype.h>
#include <string.h>
+#include <libcitadel.h>
#include "citadel.h"
#include "sysdep_decls.h"
-#include "tools.h"
#include "room_ops.h"
#include "internet_addressing.h"
#include "imap_tools.h"
-
+#include "ctdl_module.h"
#ifndef HAVE_SNPRINTF
#include "snprintf.h"
*destp = 0;
string_init(&dest, destp, destend-destp);
- /* lprintf(CTDL_DEBUG, "toimap %s\r\n", src); */
+ /* CtdlLogPrintf(CTDL_DEBUG, "toimap %s\r\n", src); */
for (;;)
{
if (state == 1)
utf7_closeb64(&dest, v, i);
- /* lprintf(CTDL_DEBUG, " -> %s\r\n", destp); */
+ /* CtdlLogPrintf(CTDL_DEBUG, " -> %s\r\n", destp); */
return string_end(&dest);
}
*destp = 0;
string_init(&dest, destp, destend-destp);
- /* lprintf(CTDL_DEBUG, "fromimap %s\r\n", src); */
+ /* CtdlLogPrintf(CTDL_DEBUG, "fromimap %s\r\n", src); */
do {
c = *p++;
}
} while (c != '\0');
- /* lprintf(CTDL_DEBUG, " -> %s\r\n", destp); */
+ /* CtdlLogPrintf(CTDL_DEBUG, " -> %s\r\n", destp); */
return string_end(&dest);
}
ret = (0 | IR_MAILBOX);
exit:
- lprintf(CTDL_DEBUG, "(That translates to \"%s\")\n", rbuf);
+ CtdlLogPrintf(CTDL_DEBUG, "(That translates to \"%s\")\n", rbuf);
return(ret);
}
int msgday, msgmonth, msgyear;
struct tm msgtm;
+ char *imap_datecmp_ascmonths[12] = {
+ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"
+ };
+
if (datestr == NULL) return(0);
/* Expecting a date in the form dd-Mmm-yyyy */
year = atoi(yearstr);
month = 0;
for (i=0; i<12; ++i) {
- if (!strcasecmp(monthstr, ascmonths[i])) {
+ if (!strcasecmp(monthstr, imap_datecmp_ascmonths[i])) {
month = i;
}
}