mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-07-23 12:18:33 +00:00
FS-5115 --resolve
This commit is contained in:
parent
7231b34de2
commit
9f98ccc105
@ -8022,6 +8022,11 @@ void sofia_handle_sip_i_info(nua_t *nua, sofia_profile_t *profile, nua_handle_t
|
|||||||
if (!strcasecmp(rec_header, "on")) {
|
if (!strcasecmp(rec_header, "on")) {
|
||||||
char *file = NULL, *tmp = NULL;
|
char *file = NULL, *tmp = NULL;
|
||||||
|
|
||||||
|
if (switch_true(switch_channel_get_variable(channel, "sip_disable_recording"))) {
|
||||||
|
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Record attempted but is disabled by sip_disable_recording variable.\n");
|
||||||
|
nua_respond(nh, 488, "Recording disabled for this channel", NUTAG_WITH_THIS_MSG(de->data->e_msg), TAG_END());
|
||||||
|
} else {
|
||||||
|
|
||||||
tmp = switch_mprintf("%s%s%s", profile->record_path ? profile->record_path : "${recordings_dir}",
|
tmp = switch_mprintf("%s%s%s", profile->record_path ? profile->record_path : "${recordings_dir}",
|
||||||
SWITCH_PATH_SEPARATOR, profile->record_template);
|
SWITCH_PATH_SEPARATOR, profile->record_template);
|
||||||
file = switch_channel_expand_variables(channel, tmp);
|
file = switch_channel_expand_variables(channel, tmp);
|
||||||
@ -8035,6 +8040,7 @@ void sofia_handle_sip_i_info(nua_t *nua, sofia_profile_t *profile, nua_handle_t
|
|||||||
free(file);
|
free(file);
|
||||||
file = NULL;
|
file = NULL;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
const char *file;
|
const char *file;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user