1
0
Fork 0

MM4 incoming fix -- now using unified prefix stuff

This commit is contained in:
bagyenda 2008-07-02 16:25:16 +00:00
parent ce84ac2e7b
commit 6445ca1403
3 changed files with 16 additions and 10 deletions

View File

@ -1,3 +1,5 @@
2008-07-01 P. A. Bagyenda
* Minor fix to MM4 interface -- address formatting fix
2008-06-27 P. A. Bagyenda <bagyenda@dsmagic.com>
* Minor fix to MM4 .RES handling: use proxy sendmail command if present
2008-06-26 P. A. Bagyenda <bagyenda@dsmagic.com>

View File

@ -550,6 +550,7 @@ static void fixup_recipient(void)
#if 0
normalize_number(octstr_get_cstr(settings->unified_prefix), &xto);
#else
mms_normalize_phonenum(&xto,
octstr_get_cstr(settings->unified_prefix),
settings->strip_prefixes);
@ -558,14 +559,14 @@ static void fixup_recipient(void)
} else { /* For now everything else is email. */
ttype = TEMAIL;
}
if (typ)
octstr_destroy(typ);
octstr_destroy(typ);
}
static void fixup_sender(void)
{
int i;
/* Find the TYPE=xxx element. If it is there, it is a number. Strip the @ */
if (!xfrom) return;
@ -587,6 +588,10 @@ static void fixup_sender(void)
else if (xproxy == NULL)
xproxy = octstr_copy(xfrom, i+1, octstr_len(xfrom));
}
/* clean the number. */
_mms_fixup_address(&xfrom,
octstr_get_cstr(settings->unified_prefix),
settings->strip_prefixes, 1);
}
static void fixup_address_type(List *headers, char *hdr)
@ -611,10 +616,14 @@ static void fixup_address_type(List *headers, char *hdr)
octstr_delete(value, k, octstr_len(value));
}
}
_mms_fixup_address(&value,
octstr_get_cstr(settings->unified_prefix),
settings->strip_prefixes, 1);
http_header_add(headers, octstr_get_cstr(name), octstr_get_cstr(value));
loop:
if (value) octstr_destroy(value);
if (name) octstr_destroy(name);
octstr_destroy(value);
octstr_destroy(name);
}
http_destroy_headers(l);
}

View File

@ -3,9 +3,4 @@
- Need to parameterise some values: response messages (say on failed content adaptation)
- Test suite
- Correct handling of unrecognised mms headers. spec says pass them un-changed.
- Queue module needs to be de-coupled slightly from storage, so that mmsproxy can run on a separate box
but be able to initiate queue writes/reads over network. Hence pieces can run on separate boxes
(with mmsrelay providing network service for queue functions)
- Generalise billing interface
- Move outgoing VASP user/pass into URL