Commit ac4ee1bf authored by rswindell's avatar rswindell
Browse files

REPLYTOLIST gets the RFC8822REPLYTO treatment. It was the last of the

MIME-decoded header fields not to be handled appropriately in the mail server.
parent 340199db
......@@ -724,7 +724,8 @@ static ulong sockmimetext(SOCKET socket, const char* prot, CRYPT_SESSION sess, s
if(!sockprintf(socket,prot,sess,"Cc: %s", p == NULL ? msg->cc_list : p))
return(0);
np=NULL;
if((p = smb_get_hfield(msg, RFC822REPLYTO, NULL)) == NULL) {
p = smb_get_hfield(msg, RFC822REPLYTO, NULL);
if(p == NULL && (p = msg->replyto_list) == NULL) {
np=msg->replyto;
if(msg->replyto_net.type==NET_INTERNET)
p=msg->replyto_net.addr;
......@@ -3634,6 +3635,16 @@ static void smtp_thread(void* arg)
free(np);
}
}
if((p = smb_get_hfield(&msg, RFC822REPLYTO, &hfield)) != NULL) {
char* np = strdup(p);
if(np != NULL) {
if(mimehdr_value_decode(np, &msg))
smb_hfield_str(&msg, REPLYTOLIST, np);
else
hfield->type = REPLYTOLIST;
free(np);
}
}
if((p = smb_get_hfield(&msg, RFC822SUBJECT, &hfield)) != NULL) {
char* np = strdup(p);
if(np != NULL) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment