imap idle not implemented right
Bheam opened this issue · comments
idle is responding with + idling, but is not supposed to show tag. this prevents idle from working on strict clients.
fix can be something like:
int imap_cmd_parser_idle(int argc, char **argv, IMAP_CONTEXT *pcontext)
{
size_t string_length = 0;
if (!pcontext->is_authed())
return 1804;
if (argc != 2)
return 1800;
gx_strlcpy(pcontext->tag_string, argv[0], arsizeof(pcontext->tag_string));
pcontext->sched_stat = SCHED_STAT_IDLING;
auto imap_reply_str = resource_get_imap_code(1602, 1, &string_length);
pcontext->connection.write(imap_reply_str, string_length);
return 0;
}
Fixed, thanks.
3f5ccc8