以Header only方式收取IMAP,POP邮件,然后Reply,会发现content中有内容
0赞
发表于 2018/12/29 10:19:21
阅读(1604)
[DESCRIPTION]
以Header only方式收取IMAP,POP邮件,然后Reply,会发现content中有内容,不需要显示相应的内容。
[SOLUTION]
10A:
IMAP的修改方案:
在函数srv_email_imap4_recv_fsm_received中
将CODE按如下方式进行屏蔽:
/*if ((state_p->download_opt == SRV_EMAIL_DOWNLOAD_HEADER ||
record_p->size > state_p->download_size) &&
text_cont_p)
{
state_p->curr_cont_p = text_cont_p;
}
*/
// else
if (record_p->size <= state_p->download_size)
{
if (state_p->download_opt == SRV_EMAIL_DOWNLOAD_HEADER_TEXT)
{
state_p->curr_cont_p = msg_env_p->cont_p;
}
else if (state_p->download_opt == SRV_EMAIL_DOWNLOAD_ALL)
{
state_p->curr_cont_p = msg_env_p->cont_p;
state_p->curr_att_p = msg_env_p->attach_p;
}
// }
POP的修改icfans方案:
对于pop3的邮箱,请将emailsrvgprot.h中EMAIL_MSG_TEXT_DOWNLOAD_SIZE_FOR_POP3的值设为0.即可