From e804d95618c33bbd5e5f744571ef1d1af3e8b24f Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Mon, 20 Aug 2012 12:06:36 -0500 Subject: [PATCH] add _preconfigured_t38_options as a back door for opal --- src/mod/applications/mod_spandsp/mod_spandsp_fax.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/mod/applications/mod_spandsp/mod_spandsp_fax.c b/src/mod/applications/mod_spandsp/mod_spandsp_fax.c index d5b80b6e09..0b8f5d4f61 100644 --- a/src/mod/applications/mod_spandsp/mod_spandsp_fax.c +++ b/src/mod/applications/mod_spandsp/mod_spandsp_fax.c @@ -1102,8 +1102,14 @@ static t38_mode_t request_t38(pvt_t *pvt) enabled = 0; } + + if (enabled) { - t38_options = switch_core_session_alloc(session, sizeof(*t38_options)); + + if (!(t38_options = switch_channel_get_private(channel, "_preconfigured_t38_options"))) { + t38_options = switch_core_session_alloc(session, sizeof(*t38_options)); + switch_channel_set_private(channel, "_preconfigured_t38_options", NULL); + } t38_options->T38MaxBitRate = (pvt->disable_v17) ? 9600 : 14400; t38_options->T38FaxVersion = 0;