提交 277ce6d0 authored 作者: Brian West's avatar Brian West

FS-8789: remove ability to swap to personal canvas while recording and prevent…

FS-8789: remove ability to swap to personal canvas while recording and prevent recording while personal canvas is on.
上级 46ebf3ce
......@@ -1013,6 +1013,10 @@ switch_status_t conference_api_sub_vid_personal(conference_obj_t *conference, sw
if (argv[2]) {
on = switch_true(argv[2]);
if (on) {
if (conference->record_count > 0) {
stream->write_function(stream, "-ERR conference is recording, not enabling vid-personal.\n");
return SWITCH_STATUS_SUCCESS;
}
conference_utils_set_flag(conference, CFLAG_PERSONAL_CANVAS);
} else {
conference_utils_clear_flag(conference, CFLAG_PERSONAL_CANVAS);
......@@ -2411,6 +2415,11 @@ switch_status_t conference_api_sub_record(conference_obj_t *conference, switch_s
return SWITCH_STATUS_GENERR;
}
if (conference_utils_test_flag(conference, CFLAG_PERSONAL_CANVAS)) {
stream->write_function(stream, "-ERR Personal Canvas enabled, recording not permitted.\n");
return SWITCH_STATUS_SUCCESS;
}
if (argv[3]) {
if (argv[3]) {
......
......@@ -60,6 +60,11 @@ void conference_record_launch_thread(conference_obj_t *conference, char *path, i
return;
}
if (conference_utils_test_flag(conference, CFLAG_PERSONAL_CANVAS)) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Personal Canvas enabled, recording not permitted.\n");
return;
}
rec->conference = conference;
rec->path = switch_core_strdup(pool, path);
rec->pool = pool;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论