Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
0e3b4cad
提交
0e3b4cad
authored
6月 05, 2007
作者:
Anthony Minessale
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update
git-svn-id:
http://svn.freeswitch.org/svn/freeswitch/trunk@5267
d0543943-73ff-0310-b7d9-9358b9ac24b2
上级
b7c178f2
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
15 行增加
和
13 行删除
+15
-13
switch_utils.h
src/include/switch_utils.h
+3
-1
switch_caller.c
src/switch_caller.c
+11
-11
switch_channel.c
src/switch_channel.c
+1
-1
没有找到文件。
src/include/switch_utils.h
浏览文件 @
0e3b4cad
...
...
@@ -177,11 +177,13 @@ switch_mutex_unlock(obj->flag_mutex);
#define switch_set_string(_dst, _src) switch_copy_string(_dst, _src, sizeof(_dst))
static
__inline__
void
switch_clean_string
(
char
*
s
)
static
__inline__
char
*
switch_clean_string
(
char
*
s
)
{
char
*
p
;
for
(
p
=
s
;
p
&&
*
p
;
p
++
)
{
uint8_t
x
=
(
uint8_t
)
*
p
;
if
(
x
<
32
||
x
>
127
)
{
*
p
=
' '
;
}
}
return
s
;
}
...
...
src/switch_caller.c
浏览文件 @
0e3b4cad
...
...
@@ -51,17 +51,17 @@ SWITCH_DECLARE(switch_caller_profile_t *) switch_caller_profile_new(switch_memor
if
(
!
context
)
{
context
=
"default"
;
}
profile
->
username
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
username
));
profile
->
dialplan
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
dialplan
));
profile
->
caller_id_name
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
caller_id_name
));
profile
->
caller_id_number
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
caller_id_number
));
profile
->
network_addr
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
network_addr
));
profile
->
ani
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
ani
));
profile
->
aniii
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
aniii
));
profile
->
rdnis
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
rdnis
));
profile
->
source
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
source
));
profile
->
context
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
context
));
profile
->
destination_number
=
switch_c
ore_strdup
(
pool
,
switch_str_nil
(
destination_number
));
profile
->
username
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
username
)
));
profile
->
dialplan
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
dialplan
)
));
profile
->
caller_id_name
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
caller_id_name
)
));
profile
->
caller_id_number
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
caller_id_number
)
));
profile
->
network_addr
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
network_addr
)
));
profile
->
ani
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
ani
)
));
profile
->
aniii
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
aniii
)
));
profile
->
rdnis
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
rdnis
)
));
profile
->
source
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
source
)
));
profile
->
context
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
context
)
));
profile
->
destination_number
=
switch_c
lean_string
(
switch_core_strdup
(
pool
,
switch_str_nil
(
destination_number
)
));
switch_set_flag
(
profile
,
SWITCH_CPF_SCREEN
);
}
...
...
src/switch_channel.c
浏览文件 @
0e3b4cad
...
...
@@ -389,7 +389,7 @@ SWITCH_DECLARE(switch_status_t) switch_channel_set_variable(switch_channel_t *ch
switch_mutex_lock
(
channel
->
profile_mutex
);
switch_core_hash_delete
(
channel
->
variables
,
varname
);
if
(
!
switch_strlen_zero
(
value
))
{
switch_core_hash_insert_dup
(
channel
->
variables
,
varname
,
switch_c
ore_session_strdup
(
channel
->
session
,
value
));
switch_core_hash_insert_dup
(
channel
->
variables
,
varname
,
switch_c
lean_string
(
switch_core_session_strdup
(
channel
->
session
,
value
)
));
}
else
{
switch_core_hash_delete
(
channel
->
variables
,
varname
);
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论