From 8773fab49063c12ae76021f442e20a8d6dbc9454 Mon Sep 17 00:00:00 2001 From: Brian West Date: Tue, 23 Aug 2011 20:51:01 -0500 Subject: [PATCH] url decode these variables just incase --- .../applications/mod_spandsp/mod_spandsp_fax.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/src/mod/applications/mod_spandsp/mod_spandsp_fax.c b/src/mod/applications/mod_spandsp/mod_spandsp_fax.c index 34562faadd..0504b0b082 100644 --- a/src/mod/applications/mod_spandsp/mod_spandsp_fax.c +++ b/src/mod/applications/mod_spandsp/mod_spandsp_fax.c @@ -997,13 +997,25 @@ static pvt_t *pvt_init(switch_core_session_t *session, mod_spandsp_fax_applicati } if ((tmp = switch_channel_get_variable(channel, "fax_ident"))) { - pvt->ident = switch_core_session_strdup(session, tmp); + char *data = NULL; + + data = strdup(tmp); + switch_url_decode(data); + pvt->ident = switch_core_session_strdup(session, data); + + switch_safe_free(data); } else { pvt->ident = switch_core_session_strdup(session, globals.ident); } if ((tmp = switch_channel_get_variable(channel, "fax_header"))) { - pvt->header = switch_core_session_strdup(session, tmp); + char *data = NULL; + + data = strdup(tmp); + switch_url_decode(data); + pvt->header = switch_core_session_strdup(session, data); + + switch_safe_free(data); } else { pvt->header = switch_core_session_strdup(session, globals.header); }