*
* Copyright (c) 2000-2009 by Art Cancro and others.
*
- * This program is free software; you can redistribute it and/or modify
+ * This program is open source software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
}
if (match) {
IAPrintf("* %s (\\NoSelect \\HasChildren) \"/\" ", verb);
- plain_imap_strout(fl->f_name);
+ IPutStr(fl->f_name, (fl->f_name)?strlen(fl->f_name):0);
IAPuts("\r\n");
}
}
}
if (yes_output_this_room) {
- imap_mailboxname(MailboxName, sizeof MailboxName, qrbuf);
+ long len;
+ len = imap_mailboxname(MailboxName, sizeof MailboxName, qrbuf);
match = 0;
for (i=0; i<ImapFilter->num_patterns; ++i) {
if (imap_mailbox_matches_pattern(ChrPtr(ImapFilter->patterns[i]), MailboxName)) {
}
if (match) {
IAPrintf("* %s (%s) \"/\" ", ImapFilter->verb, return_options);
- plain_imap_strout(MailboxName);
+ IPutStr(MailboxName, len);
IAPuts("\r\n");
}
}
*/
void imap_list(int num_parms, ConstStr *Params)
{
- citimap *Imap = IMAP;
+ struct CitContext *CCC = CC;
+ citimap *Imap = CCCIMAP;
int i, j, paren_nest;
ImapRoomListFilter ImapFilter;
int selection_left = (-1);
int selection_right = (-1);
int return_left = (-1);
- int return_right = (-1);
int root_pos = 2;
int patterns_left = 3;
int patterns_right = 3;
&Params[i],
1);
- syslog(LOG_DEBUG, "evaluating <%s>\n", Params[i].Key);
+ IMAP_syslog(LOG_DEBUG, "evaluating <%s>", Params[i].Key);
if (!strcasecmp(Params[i].Key, "SUBSCRIBED")) {
ImapFilter.return_subscribed = 1;
}
if (paren_nest == 0) {
- return_right = i; /* found end of patterns */
i = num_parms + 1; /* break out of the loop */
}
}
*/
for (i=0; i<ImapFilter.num_patterns; ++i) {
FreeStrBuf(&ImapFilter.patterns[i]);
- free(ImapFilter.patterns);
-
}
+ free(ImapFilter.patterns);
IReplyPrintf("OK %s completed", ImapFilter.verb);
}