From 3dca2ebb00564ad01902a949d9b9a692d3c29d45 Mon Sep 17 00:00:00 2001 From: Rupa Schomaker Date: Mon, 9 May 2011 09:45:35 -0500 Subject: [PATCH 1/3] mod_lcr - FS-3283 --resolve fix as xml for larger number of arguments --- src/mod/applications/mod_lcr/mod_lcr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mod/applications/mod_lcr/mod_lcr.c b/src/mod/applications/mod_lcr/mod_lcr.c index fcb75ef4d5..f475671ef1 100644 --- a/src/mod/applications/mod_lcr/mod_lcr.c +++ b/src/mod/applications/mod_lcr/mod_lcr.c @@ -1664,7 +1664,7 @@ static void write_data(switch_stream_handle_t *stream, switch_bool_t as_xml, con SWITCH_STANDARD_API(dialplan_lcr_function) { - char *argv[4] = { 0 }; + char *argv[9] = { 0 }; int argc; char *mydata = NULL; //char *dialstring = NULL; From 5fa9619fe70e30e75fb24cfe87570b63d7d65071 Mon Sep 17 00:00:00 2001 From: Rupa Schomaker Date: Mon, 9 May 2011 11:19:58 -0500 Subject: [PATCH 2/3] mod_lcr - FS-3284 --resolve - fix malformed XML when has embedded %s --- src/mod/applications/mod_lcr/mod_lcr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mod/applications/mod_lcr/mod_lcr.c b/src/mod/applications/mod_lcr/mod_lcr.c index f475671ef1..c0d99dfc35 100644 --- a/src/mod/applications/mod_lcr/mod_lcr.c +++ b/src/mod/applications/mod_lcr/mod_lcr.c @@ -1825,7 +1825,7 @@ SWITCH_STANDARD_API(dialplan_lcr_function) if (as_xml) { event_xml = switch_event_xmlize(current->fields, SWITCH_VA_NONE); event_str = switch_xml_toxml(event_xml, SWITCH_FALSE); - stream->write_function(stream, event_str); + stream->write_function(stream, "%s", event_str); switch_xml_free(event_xml); switch_safe_free(event_str); } From 154731a777377c3daf5fa4ffed705c0f942d33de Mon Sep 17 00:00:00 2001 From: Michael S Collins Date: Mon, 9 May 2011 09:41:50 -0700 Subject: [PATCH 3/3] Add jaybinks' tel: patch --- src/mod/endpoints/mod_sofia/sofia_glue.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/mod/endpoints/mod_sofia/sofia_glue.c b/src/mod/endpoints/mod_sofia/sofia_glue.c index ab37ecd7f7..cc21bd0c04 100644 --- a/src/mod/endpoints/mod_sofia/sofia_glue.c +++ b/src/mod/endpoints/mod_sofia/sofia_glue.c @@ -2171,6 +2171,15 @@ switch_status_t sofia_glue_do_invite(switch_core_session_t *session) if (!strncasecmp(url_str, "sips:", 5)) { s = url_str + 5; } + + /* tel: patch from jaybinks, added by MC + It compiles but I don't have a way to test it + */ + if (!strncasecmp(url_str, "tel:", 4)) { + switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), + SWITCH_LOG_ERROR, "URL Error! tel: uri's not supported at this time\n"); + return SWITCH_STATUS_FALSE; + } if (!s) { s = url_str; }