Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
d5ba2f3e
提交
d5ba2f3e
authored
6月 07, 2010
作者:
Anthony Minessale
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add RTP_BUG_IGNORE_MARK_BIT to list of bug tolerances
上级
23b1fc61
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
23 行增加
和
3 行删除
+23
-3
switch_types.h
src/include/switch_types.h
+14
-1
sofia.c
src/mod/endpoints/mod_sofia/sofia.c
+7
-0
switch_rtp.c
src/switch_rtp.c
+2
-2
没有找到文件。
src/include/switch_types.h
浏览文件 @
d5ba2f3e
...
@@ -554,7 +554,7 @@ typedef enum {
...
@@ -554,7 +554,7 @@ typedef enum {
*/
*/
RTP_BUG_SONUS_SEND_INVALID_TIMESTAMP_2833
=
(
1
<<
1
)
RTP_BUG_SONUS_SEND_INVALID_TIMESTAMP_2833
=
(
1
<<
1
)
,
/*
/*
Sonus wrongly expects that, when sending a multi-packet 2833 DTMF event, The sender
Sonus wrongly expects that, when sending a multi-packet 2833 DTMF event, The sender
should increment the RTP timestamp in each packet when, in reality, the sender should
should increment the RTP timestamp in each packet when, in reality, the sender should
...
@@ -573,6 +573,19 @@ typedef enum {
...
@@ -573,6 +573,19 @@ typedef enum {
This flag will cause each packet to have a new timestamp.
This flag will cause each packet to have a new timestamp.
*/
*/
RTP_BUG_IGNORE_MARK_BIT
=
(
1
<<
2
)
/*
A Huawei SBC has been discovered that sends the mark bit on every single RTP packet.
Since this causes the RTP stack to flush it's buffers, it horribly messes up the timing on the channel.
This flag will do nothing when an inbound packet contains the mark bit.
*/
}
switch_rtp_bug_flag_t
;
}
switch_rtp_bug_flag_t
;
#ifdef _MSC_VER
#ifdef _MSC_VER
...
...
src/mod/endpoints/mod_sofia/sofia.c
浏览文件 @
d5ba2f3e
...
@@ -2125,6 +2125,13 @@ static void parse_rtp_bugs(sofia_profile_t *profile, const char *str)
...
@@ -2125,6 +2125,13 @@ static void parse_rtp_bugs(sofia_profile_t *profile, const char *str)
profile
->
auto_rtp_bugs
&=
~
RTP_BUG_SONUS_SEND_INVALID_TIMESTAMP_2833
;
profile
->
auto_rtp_bugs
&=
~
RTP_BUG_SONUS_SEND_INVALID_TIMESTAMP_2833
;
}
}
if
(
switch_stristr
(
"RTP_BUG_IGNORE_MARK_BIT"
,
str
))
{
profile
->
auto_rtp_bugs
|=
RTP_BUG_IGNORE_MARK_BIT
;
}
if
(
switch_stristr
(
"~RTP_BUG_IGNORE_MARK_BIT"
,
str
))
{
profile
->
auto_rtp_bugs
&=
~
RTP_BUG_IGNORE_MARK_BIT
;
}
}
}
...
...
src/switch_rtp.c
浏览文件 @
d5ba2f3e
...
@@ -2043,7 +2043,7 @@ static switch_status_t read_rtp_packet(switch_rtp_t *rtp_session, switch_size_t
...
@@ -2043,7 +2043,7 @@ static switch_status_t read_rtp_packet(switch_rtp_t *rtp_session, switch_size_t
if
(
rtp_session
->
jb
&&
rtp_session
->
recv_msg
.
header
.
version
==
2
&&
*
bytes
)
{
if
(
rtp_session
->
jb
&&
rtp_session
->
recv_msg
.
header
.
version
==
2
&&
*
bytes
)
{
if
(
rtp_session
->
recv_msg
.
header
.
m
&&
rtp_session
->
recv_msg
.
header
.
pt
!=
rtp_session
->
recv_te
&&
if
(
rtp_session
->
recv_msg
.
header
.
m
&&
rtp_session
->
recv_msg
.
header
.
pt
!=
rtp_session
->
recv_te
&&
!
switch_test_flag
(
rtp_session
,
SWITCH_RTP_FLAG_VIDEO
))
{
!
switch_test_flag
(
rtp_session
,
SWITCH_RTP_FLAG_VIDEO
)
&&
!
(
rtp_session
->
rtp_bugs
&
RTP_BUG_IGNORE_MARK_BIT
)
)
{
stfu_n_reset
(
rtp_session
->
jb
);
stfu_n_reset
(
rtp_session
->
jb
);
}
}
...
@@ -2395,7 +2395,7 @@ static int rtp_common_read(switch_rtp_t *rtp_session, switch_payload_t *payload_
...
@@ -2395,7 +2395,7 @@ static int rtp_common_read(switch_rtp_t *rtp_session, switch_payload_t *payload_
}
}
if
(
bytes
&&
rtp_session
->
recv_msg
.
header
.
m
&&
rtp_session
->
recv_msg
.
header
.
pt
!=
rtp_session
->
recv_te
&&
if
(
bytes
&&
rtp_session
->
recv_msg
.
header
.
m
&&
rtp_session
->
recv_msg
.
header
.
pt
!=
rtp_session
->
recv_te
&&
!
switch_test_flag
(
rtp_session
,
SWITCH_RTP_FLAG_VIDEO
))
{
!
switch_test_flag
(
rtp_session
,
SWITCH_RTP_FLAG_VIDEO
)
&&
!
(
rtp_session
->
rtp_bugs
&
RTP_BUG_IGNORE_MARK_BIT
)
)
{
rtp_flush_read_buffer
(
rtp_session
,
SWITCH_RTP_FLUSH_ONCE
);
rtp_flush_read_buffer
(
rtp_session
,
SWITCH_RTP_FLUSH_ONCE
);
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论