Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
fb43f805
提交
fb43f805
authored
12月 18, 2011
作者:
Marc Olivier Chouinard
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
FS-3705 --resolve
上级
8379a292
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
32 行增加
和
5 行删除
+32
-5
conference.conf.xml
conf/autoload_configs/conference.conf.xml
+2
-0
mod_conference.c
src/mod/applications/mod_conference/mod_conference.c
+30
-5
没有找到文件。
conf/autoload_configs/conference.conf.xml
浏览文件 @
fb43f805
...
...
@@ -118,6 +118,8 @@
<!-- <param name="ivr-dtmf-timeout" value="500"/> -->
<!-- How much to wait for the first DTMF, 0 forever -->
<!-- <param name="ivr-input-timeout" value="0" /> -->
<!-- Delay before a conference is asked to be terminated -->
<!-- <param name="endconf-grace-time" value="120" /> -->
</profile>
<profile
name=
"wideband"
>
...
...
src/mod/applications/mod_conference/mod_conference.c
浏览文件 @
fb43f805
...
...
@@ -312,6 +312,10 @@ typedef struct conference_obj {
uint32_t
eflags
;
uint32_t
verbose_events
;
int
end_count
;
/* allow extra time after 'endconf' member leaves */
switch_time_t
endconf_time
;
int
endconf_grace_time
;
uint32_t
relationship_total
;
uint32_t
score
;
int
mux_loop_count
;
...
...
@@ -900,7 +904,9 @@ static switch_status_t conference_add_member(conference_obj_t *conference, confe
conference
->
count
++
;
if
(
switch_test_flag
(
member
,
MFLAG_ENDCONF
))
{
if
(
conference
->
end_count
++
)
{};
if
(
conference
->
end_count
++
)
{
conference
->
endconf_time
=
0
;
}
}
conference_send_presence
(
conference
);
...
...
@@ -1107,7 +1113,8 @@ static switch_status_t conference_del_member(conference_obj_t *conference, confe
if
(
switch_test_flag
(
member
,
MFLAG_ENDCONF
))
{
if
(
!--
conference
->
end_count
)
{
switch_set_flag_locked
(
conference
,
CFLAG_DESTRUCT
);
//switch_set_flag_locked(conference, CFLAG_DESTRUCT);
conference
->
endconf_time
=
switch_epoch_time_now
(
NULL
);
}
}
...
...
@@ -1693,6 +1700,13 @@ static void *SWITCH_THREAD_FUNC conference_thread_run(switch_thread_t *thread, v
switch_core_destroy_memory_pool
(
&
pool
);
}
if
(
!
conference
->
end_count
&&
conference
->
endconf_time
&&
switch_epoch_time_now
(
NULL
)
-
conference
->
endconf_time
>
conference
->
endconf_grace_time
)
{
switch_log_printf
(
SWITCH_CHANNEL_LOG
,
SWITCH_LOG_DEBUG
,
"Conference %s: endconf grace time exceeded (%u)
\n
"
,
conference
->
name
,
conference
->
endconf_grace_time
);
switch_set_flag
(
conference
,
CFLAG_DESTRUCT
);
}
switch_mutex_unlock
(
conference
->
mutex
);
}
/* Rinse ... Repeat */
...
...
@@ -4411,6 +4425,11 @@ static void conference_xlist(conference_obj_t *conference, switch_xml_t x_confer
switch_xml_set_attr_d
(
x_conference
,
"recording"
,
"true"
);
}
if
(
conference
->
endconf_grace_time
>
0
)
{
switch_snprintf
(
i
,
sizeof
(
i
),
"%u"
,
conference
->
endconf_grace_time
);
switch_xml_set_attr_d
(
x_conference
,
"endconf_grace_time"
,
ival
);
}
switch_snprintf
(
i
,
sizeof
(
i
),
"%d"
,
switch_epoch_time_now
(
NULL
)
-
conference
->
run_time
);
switch_xml_set_attr_d
(
x_conference
,
"run_time"
,
ival
);
...
...
@@ -6791,6 +6810,7 @@ static conference_obj_t *conference_new(char *name, conf_xml_cfg_t cfg, switch_c
char
*
auto_record
=
NULL
;
char
*
conference_log_dir
=
NULL
;
char
*
terminate_on_silence
=
NULL
;
char
*
endconf_grace_time
=
NULL
;
char
uuid_str
[
SWITCH_UUID_FORMATTED_LENGTH
+
1
];
switch_uuid_t
uuid
;
switch_codec_implementation_t
read_impl
=
{
0
};
...
...
@@ -6998,6 +7018,8 @@ static conference_obj_t *conference_new(char *name, conf_xml_cfg_t cfg, switch_c
auto_record
=
val
;
}
else
if
(
!
strcasecmp
(
var
,
"terminate-on-silence"
)
&&
!
zstr
(
val
))
{
terminate_on_silence
=
val
;
}
else
if
(
!
strcasecmp
(
var
,
"endconf-grace-time"
)
&&
!
zstr
(
val
))
{
endconf_grace_time
=
val
;
}
}
...
...
@@ -7222,9 +7244,12 @@ static conference_obj_t *conference_new(char *name, conf_xml_cfg_t cfg, switch_c
if
(
!
zstr
(
auto_record
))
{
conference
->
auto_record
=
switch_core_strdup
(
conference
->
pool
,
auto_record
);
}
if
(
!
zstr
(
terminate_on_silence
))
{
conference
->
terminate_on_silence
=
atoi
(
terminate_on_silence
);
}
if
(
!
zstr
(
terminate_on_silence
))
{
conference
->
terminate_on_silence
=
atoi
(
terminate_on_silence
);
}
if
(
!
zstr
(
endconf_grace_time
))
{
conference
->
endconf_grace_time
=
atoi
(
endconf_grace_time
);
}
if
(
!
zstr
(
verbose_events
)
&&
switch_true
(
verbose_events
))
{
conference
->
verbose_events
=
1
;
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论