Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
f6e5cae7
提交
f6e5cae7
authored
8月 10, 2012
作者:
Kapil Gupta
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fixing modify resp issue
上级
d46b6cd4
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
167 行增加
和
117 行删除
+167
-117
media_gateway_cmd_handler.c
...d/endpoints/mod_media_gateway/media_gateway_cmd_handler.c
+159
-112
media_gateway_xml.c
src/mod/endpoints/mod_media_gateway/media_gateway_xml.c
+8
-5
没有找到文件。
src/mod/endpoints/mod_media_gateway/media_gateway_cmd_handler.c
浏览文件 @
f6e5cae7
差异被折叠。
点击展开。
src/mod/endpoints/mod_media_gateway/media_gateway_xml.c
浏览文件 @
f6e5cae7
...
...
@@ -71,7 +71,7 @@ switch_status_t config_profile(megaco_profile_t *profile, switch_bool_t reload)
for
(
mg_term
=
switch_xml_child
(
mg_phys_terms
,
"map"
);
mg_term
;
mg_term
=
mg_term
->
next
)
{
// <map termination-id-prefix="Term1/" termination-id-base="1" tech="freetdm" channel-prefix="wp2" channel-map"1-15,17-31"/>
const
char
*
prefix
=
switch_xml_attr
(
mg_term
,
"termination-id-prefix"
);
//
const char *sztermination_id_base = switch_xml_attr(mg_term, "termination-id-base");
const
char
*
sztermination_id_base
=
switch_xml_attr
(
mg_term
,
"termination-id-base"
);
const
char
*
tech
=
switch_xml_attr
(
mg_term
,
"tech"
);
const
char
*
channel_prefix
=
switch_xml_attr
(
mg_term
,
"channel-prefix"
);
const
char
*
channel_map
=
switch_xml_attr
(
mg_term
,
"channel-map"
);
...
...
@@ -84,6 +84,7 @@ switch_status_t config_profile(megaco_profile_t *profile, switch_bool_t reload)
int
chanmap_count
=
0
;
int
i
=
0
;
int
startchan
,
endchan
,
j
;
int
mg_term_idx
=
(
sztermination_id_base
)
?
atoi
(
sztermination_id_base
)
:
1
;
/* we can have following combinations *
* i) only one channel i.e. channel-map="1"
...
...
@@ -103,14 +104,15 @@ switch_status_t config_profile(megaco_profile_t *profile, switch_bool_t reload)
startchan
=
atoi
(
chanmap
[
0
]);
endchan
=
atoi
(
chanmap
[
1
]);
for
(
j
=
startchan
;
j
<=
endchan
;
j
++
)
{
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
j
,
j
);
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
mg_term_idx
,
j
);
mg_term_idx
++
;
}
}
}
else
{
/* case (i) */
p
=
channel_map_dup
;
startchan
=
endchan
=
atoi
(
p
);
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
startchan
,
startchan
);
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
mg_term_idx
,
startchan
);
}
}
else
{
...
...
@@ -124,9 +126,10 @@ switch_status_t config_profile(megaco_profile_t *profile, switch_bool_t reload)
for
(
j
=
startchan
;
j
<=
endchan
;
j
++
)
{
if
(
0
==
i
)
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
j
,
j
);
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
mg_term_idx
,
j
);
else
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
j
,
j
-
1
);
mg_create_tdm_term
(
profile
,
tech
,
channel_prefix
,
prefix
,
mg_term_idx
,
j
-
1
);
mg_term_idx
++
;
}
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论