Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
f53b670a
提交
f53b670a
authored
1月 04, 2017
作者:
Brian West
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
FS-9916: [mod_spandsp] OB fax calls go zombie #resolve
上级
89d3e29f
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
18 行增加
和
15 行删除
+18
-15
mod_sofia.c
src/mod/endpoints/mod_sofia/mod_sofia.c
+17
-15
mod_sofia.h
src/mod/endpoints/mod_sofia/mod_sofia.h
+1
-0
没有找到文件。
src/mod/endpoints/mod_sofia/mod_sofia.c
浏览文件 @
f53b670a
...
@@ -1009,8 +1009,6 @@ static switch_status_t sofia_write_video_frame(switch_core_session_t *session, s
...
@@ -1009,8 +1009,6 @@ static switch_status_t sofia_write_video_frame(switch_core_session_t *session, s
static
switch_status_t
sofia_read_frame
(
switch_core_session_t
*
session
,
switch_frame_t
**
frame
,
switch_io_flag_t
flags
,
int
stream_id
)
static
switch_status_t
sofia_read_frame
(
switch_core_session_t
*
session
,
switch_frame_t
**
frame
,
switch_io_flag_t
flags
,
int
stream_id
)
{
{
private_object_t
*
tech_pvt
=
switch_core_session_get_private
(
session
);
private_object_t
*
tech_pvt
=
switch_core_session_get_private
(
session
);
switch_channel_t
*
channel
=
switch_core_session_get_channel
(
session
);
uint32_t
sanity
=
1000
;
switch_status_t
status
=
SWITCH_STATUS_FALSE
;
switch_status_t
status
=
SWITCH_STATUS_FALSE
;
switch_assert
(
tech_pvt
!=
NULL
);
switch_assert
(
tech_pvt
!=
NULL
);
...
@@ -1024,18 +1022,10 @@ static switch_status_t sofia_read_frame(switch_core_session_t *session, switch_f
...
@@ -1024,18 +1022,10 @@ static switch_status_t sofia_read_frame(switch_core_session_t *session, switch_f
return
SWITCH_STATUS_FALSE
;
return
SWITCH_STATUS_FALSE
;
}
}
while
(
!
(
switch_core_media_ready
(
tech_pvt
->
session
,
SWITCH_MEDIA_TYPE_AUDIO
))){
// && !switch_channel_test_flag(channel, CF_REQ_MEDIA))) {
if
(
!
(
switch_core_media_ready
(
tech_pvt
->
session
,
SWITCH_MEDIA_TYPE_AUDIO
))){
switch_ivr_parse_all_messages
(
tech_pvt
->
session
);
return
SWITCH_STATUS_INUSE
;
if
(
--
sanity
&&
switch_channel_up
(
channel
))
{
switch_yield
(
10000
);
}
else
{
switch_channel_hangup
(
tech_pvt
->
channel
,
SWITCH_CAUSE_RECOVERY_ON_TIMER_EXPIRE
);
return
SWITCH_STATUS_GENERR
;
}
}
}
sofia_set_flag_locked
(
tech_pvt
,
TFLAG_READING
);
sofia_set_flag_locked
(
tech_pvt
,
TFLAG_READING
);
if
(
sofia_test_flag
(
tech_pvt
,
TFLAG_HUP
)
||
sofia_test_flag
(
tech_pvt
,
TFLAG_BYE
))
{
if
(
sofia_test_flag
(
tech_pvt
,
TFLAG_HUP
)
||
sofia_test_flag
(
tech_pvt
,
TFLAG_BYE
))
{
...
@@ -1057,14 +1047,26 @@ static switch_status_t sofia_write_frame(switch_core_session_t *session, switch_
...
@@ -1057,14 +1047,26 @@ static switch_status_t sofia_write_frame(switch_core_session_t *session, switch_
switch_assert
(
tech_pvt
!=
NULL
);
switch_assert
(
tech_pvt
!=
NULL
);
while
(
!
(
switch_core_media_ready
(
tech_pvt
->
session
,
SWITCH_MEDIA_TYPE_AUDIO
)
&&
!
switch_channel_test_flag
(
channel
,
CF_REQ_MEDIA
)))
{
if
(
switch_channel_ready
(
channel
))
{
if
(
!
switch_core_media_ready
(
tech_pvt
->
session
,
SWITCH_MEDIA_TYPE_AUDIO
))
{
switch_yield
(
10000
);
if
(
switch_channel_up_nosig
(
channel
))
{
return
SWITCH_STATUS_SUCCESS
;
}
else
{
}
else
{
return
SWITCH_STATUS_GENERR
;
return
SWITCH_STATUS_GENERR
;
}
}
}
}
if
(
switch_channel_test_flag
(
channel
,
CF_REQ_MEDIA
))
{
if
(
++
tech_pvt
->
req_media_counter
>
2000
)
{
switch_channel_clear_flag
(
channel
,
CF_REQ_MEDIA
);
switch_channel_hangup
(
channel
,
SWITCH_CAUSE_RECOVERY_ON_TIMER_EXPIRE
);
return
SWITCH_STATUS_FALSE
;
}
else
{
return
SWITCH_STATUS_SUCCESS
;
}
}
else
{
tech_pvt
->
req_media_counter
=
0
;
}
if
(
sofia_test_flag
(
tech_pvt
,
TFLAG_HUP
))
{
if
(
sofia_test_flag
(
tech_pvt
,
TFLAG_HUP
))
{
return
SWITCH_STATUS_FALSE
;
return
SWITCH_STATUS_FALSE
;
...
...
src/mod/endpoints/mod_sofia/mod_sofia.h
浏览文件 @
f53b670a
...
@@ -841,6 +841,7 @@ struct private_object {
...
@@ -841,6 +841,7 @@ struct private_object {
uint32_t
sent_invites
;
uint32_t
sent_invites
;
uint32_t
recv_invites
;
uint32_t
recv_invites
;
uint8_t
sent_last_invite
;
uint8_t
sent_last_invite
;
uint32_t
req_media_counter
;
};
};
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论