FS-4789 --resolve
This commit is contained in:
parent
7085de2546
commit
5e62fde357
|
@ -197,7 +197,7 @@ static void event_handler(switch_event_t *event)
|
||||||
SWITCH_STANDARD_APP(t38_gateway_function)
|
SWITCH_STANDARD_APP(t38_gateway_function)
|
||||||
{
|
{
|
||||||
switch_channel_t *channel = switch_core_session_get_channel(session);
|
switch_channel_t *channel = switch_core_session_get_channel(session);
|
||||||
time_t timeout = switch_epoch_time_now(NULL) + 20;
|
int timeout = 20;
|
||||||
const char *var;
|
const char *var;
|
||||||
int argc = 0;
|
int argc = 0;
|
||||||
char *argv[2] = { 0 };
|
char *argv[2] = { 0 };
|
||||||
|
@ -226,9 +226,9 @@ SWITCH_STANDARD_APP(t38_gateway_function)
|
||||||
t38_gateway_start(session, direction, NULL);
|
t38_gateway_start(session, direction, NULL);
|
||||||
} else {
|
} else {
|
||||||
if ((var = switch_channel_get_variable(channel, "t38_gateway_detect_timeout"))) {
|
if ((var = switch_channel_get_variable(channel, "t38_gateway_detect_timeout"))) {
|
||||||
long to = atol(var);
|
int to = atoi(var);
|
||||||
if (to > -1) {
|
if (to > -1) {
|
||||||
timeout = (time_t) (switch_epoch_time_now(NULL) + to);
|
timeout = to;
|
||||||
} else {
|
} else {
|
||||||
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "%s invalid timeout value.\n", switch_channel_get_name(channel));
|
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "%s invalid timeout value.\n", switch_channel_get_name(channel));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue