grommunio / gromox

Groupware server backend for the grommunio Distribution, supporting MAPI/HTTP, RPC/HTTP, EWS, IMAP, POP3 protocols, PHP-MAPI bindings, and import from PST/OST/MSG/CDFV2/TNEF, EML/ICAL/VCF, Kopano, Zarafa

Home Page:https://gromox.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

imap idle not implemented right

Bheam opened this issue · comments

commented

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