diff --git a/mbuni/mmlib/mms_mm7soap.c b/mbuni/mmlib/mms_mm7soap.c index 6cb18e7..de99fa9 100644 --- a/mbuni/mmlib/mms_mm7soap.c +++ b/mbuni/mmlib/mms_mm7soap.c @@ -932,6 +932,11 @@ MSoapMsg_t *mm7_mmsmsg_to_soap(MmsMsg *msg, Octstr *from, List *xto, isclientside ? "SenderAddress" : "Sender", octstr_get_cstr(xfrom)); + if ((s = mms_get_header_value(msg, octstr_imm("Date"))) != NULL) { + http_header_add(m->envelope, "TimeStamp", octstr_get_cstr(s)); + octstr_destroy(s); + } + if (isclientside) { if (vaspid) http_header_add(m->envelope, "VASPID", vaspid); @@ -974,10 +979,6 @@ MSoapMsg_t *mm7_mmsmsg_to_soap(MmsMsg *msg, Octstr *from, List *xto, octstr_destroy(s); } - if ((s = mms_get_header_value(msg, octstr_imm("Date"))) != NULL) { - http_header_add(m->envelope, "TimeStamp", octstr_get_cstr(s)); - octstr_destroy(s); - } /* Should we bother to strip message part of headers??? */ headers = mime_entity_headers(m->msg);