Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
21418b08
提交
21418b08
authored
11月 06, 2010
作者:
Arnaldo Pereira
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' of git.sangoma.com:smg_freeswitch
上级
b912935c
fdd9944e
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
35 行增加
和
9 行删除
+35
-9
ftmod_sangoma_ss7_out.c
...eetdm/src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_out.c
+20
-1
ftmod_sangoma_ss7_support.c
...m/src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_support.c
+15
-8
没有找到文件。
libs/freetdm/src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_out.c
浏览文件 @
21418b08
...
@@ -335,7 +335,26 @@ void ft_to_sngss7_acm (ftdm_channel_t * ftdmchan)
...
@@ -335,7 +335,26 @@ void ft_to_sngss7_acm (ftdm_channel_t * ftdmchan)
acm
.
bckCallInd
.
isdnAccInd
.
pres
=
PRSNT_NODEF
;
acm
.
bckCallInd
.
isdnAccInd
.
pres
=
PRSNT_NODEF
;
acm
.
bckCallInd
.
isdnAccInd
.
val
=
ISDNACC_NONISDN
;
acm
.
bckCallInd
.
isdnAccInd
.
val
=
ISDNACC_NONISDN
;
acm
.
bckCallInd
.
echoCtrlDevInd
.
pres
=
PRSNT_NODEF
;
acm
.
bckCallInd
.
echoCtrlDevInd
.
pres
=
PRSNT_NODEF
;
acm
.
bckCallInd
.
echoCtrlDevInd
.
val
=
0x1
;
/* ec device present */
switch
(
ftdmchan
->
caller_data
.
bearer_capability
)
{
/**********************************************************************/
case
(
FTDM_BEARER_CAP_SPEECH
):
acm
.
bckCallInd
.
echoCtrlDevInd
.
val
=
0x1
;
break
;
/**********************************************************************/
case
(
FTDM_BEARER_CAP_64K_UNRESTRICTED
):
acm
.
bckCallInd
.
echoCtrlDevInd
.
val
=
0x0
;
break
;
/**********************************************************************/
case
(
FTDM_BEARER_CAP_3_1KHZ_AUDIO
):
acm
.
bckCallInd
.
echoCtrlDevInd
.
val
=
0x1
;
break
;
/**********************************************************************/
default:
SS7_ERROR_CHAN
(
ftdmchan
,
"Unknown Bearer capability falling back to speech%s
\n
"
,
" "
);
acm
.
bckCallInd
.
echoCtrlDevInd
.
val
=
0x1
;
break
;
/**********************************************************************/
}
/* switch (ftdmchan->caller_data.bearer_capability) */
acm
.
bckCallInd
.
sccpMethInd
.
pres
=
PRSNT_NODEF
;
acm
.
bckCallInd
.
sccpMethInd
.
pres
=
PRSNT_NODEF
;
acm
.
bckCallInd
.
sccpMethInd
.
val
=
SCCPMTH_NOIND
;
acm
.
bckCallInd
.
sccpMethInd
.
val
=
SCCPMTH_NOIND
;
...
...
libs/freetdm/src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_support.c
浏览文件 @
21418b08
...
@@ -132,7 +132,8 @@ uint8_t copy_cgPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCgPtyNum *cgPtyNum)
...
@@ -132,7 +132,8 @@ uint8_t copy_cgPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCgPtyNum *cgPtyNum)
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
/* check if the digit is a number and that is not null */
/* check if the digit is a number and that is not null */
while
(
!
(
isdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
while
(
!
(
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
/* move on to the next value */
/* move on to the next value */
k
++
;
k
++
;
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
...
@@ -141,14 +142,15 @@ uint8_t copy_cgPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCgPtyNum *cgPtyNum)
...
@@ -141,14 +142,15 @@ uint8_t copy_cgPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCgPtyNum *cgPtyNum)
/* check if tmp is null or a digit */
/* check if tmp is null or a digit */
if
(
tmp
[
0
]
!=
'\0'
)
{
if
(
tmp
[
0
]
!=
'\0'
)
{
/* push it into the lower nibble */
/* push it into the lower nibble */
lower
=
atoi
(
&
tmp
[
0
]
);
lower
=
strtol
(
&
tmp
[
0
],
(
char
**
)
NULL
,
16
);
/* move to the next digit */
/* move to the next digit */
k
++
;
k
++
;
/* grab a digit from the ftdm digits */
/* grab a digit from the ftdm digits */
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
/* check if the digit is a number and that is not null */
/* check if the digit is a number and that is not null */
while
(
!
(
isdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
while
(
!
(
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
k
++
;
k
++
;
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
cid_num
.
digits
[
k
];
}
/* while(!(isdigit(tmp))) */
}
/* while(!(isdigit(tmp))) */
...
@@ -156,7 +158,7 @@ uint8_t copy_cgPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCgPtyNum *cgPtyNum)
...
@@ -156,7 +158,7 @@ uint8_t copy_cgPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCgPtyNum *cgPtyNum)
/* check if tmp is null or a digit */
/* check if tmp is null or a digit */
if
(
tmp
[
0
]
!=
'\0'
)
{
if
(
tmp
[
0
]
!=
'\0'
)
{
/* push the digit into the upper nibble */
/* push the digit into the upper nibble */
upper
=
(
atoi
(
&
tmp
[
0
]
))
<<
4
;
upper
=
(
strtol
(
&
tmp
[
0
],
(
char
**
)
NULL
,
16
))
<<
4
;
}
else
{
}
else
{
/* there is no upper ... fill in 0 */
/* there is no upper ... fill in 0 */
upper
=
0x0
;
upper
=
0x0
;
...
@@ -243,7 +245,8 @@ uint8_t copy_cdPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCdPtyNum *cdPtyNum)
...
@@ -243,7 +245,8 @@ uint8_t copy_cdPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCdPtyNum *cdPtyNum)
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
/* check if the digit is a number and that is not null */
/* check if the digit is a number and that is not null */
while
(
!
(
isdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
while
(
!
(
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
/* move on to the next value */
/* move on to the next value */
k
++
;
k
++
;
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
...
@@ -252,14 +255,15 @@ uint8_t copy_cdPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCdPtyNum *cdPtyNum)
...
@@ -252,14 +255,15 @@ uint8_t copy_cdPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCdPtyNum *cdPtyNum)
/* check if tmp is null or a digit */
/* check if tmp is null or a digit */
if
(
tmp
[
0
]
!=
'\0'
)
{
if
(
tmp
[
0
]
!=
'\0'
)
{
/* push it into the lower nibble */
/* push it into the lower nibble */
lower
=
atoi
(
&
tmp
[
0
]
);
lower
=
strtol
(
&
tmp
[
0
],
(
char
**
)
NULL
,
16
);
/* move to the next digit */
/* move to the next digit */
k
++
;
k
++
;
/* grab a digit from the ftdm digits */
/* grab a digit from the ftdm digits */
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
/* check if the digit is a number and that is not null */
/* check if the digit is a number and that is not null */
while
(
!
(
isdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
while
(
!
(
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
k
++
;
k
++
;
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
tmp
[
0
]
=
ftdm
->
dnis
.
digits
[
k
];
}
/* while(!(isdigit(tmp))) */
}
/* while(!(isdigit(tmp))) */
...
@@ -267,7 +271,7 @@ uint8_t copy_cdPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCdPtyNum *cdPtyNum)
...
@@ -267,7 +271,7 @@ uint8_t copy_cdPtyNum_to_sngss7(ftdm_caller_data_t *ftdm, SiCdPtyNum *cdPtyNum)
/* check if tmp is null or a digit */
/* check if tmp is null or a digit */
if
(
tmp
[
0
]
!=
'\0'
)
{
if
(
tmp
[
0
]
!=
'\0'
)
{
/* push the digit into the upper nibble */
/* push the digit into the upper nibble */
upper
=
(
atoi
(
&
tmp
[
0
]
))
<<
4
;
upper
=
(
strtol
(
&
tmp
[
0
],
(
char
**
)
NULL
,
16
))
<<
4
;
}
else
{
}
else
{
/* there is no upper ... fill in ST */
/* there is no upper ... fill in ST */
upper
=
0xF0
;
upper
=
0xF0
;
...
@@ -984,6 +988,7 @@ ftdm_status_t encode_subAddrIE_nsap(const char *subAddr, char *subAddrIE, int ty
...
@@ -984,6 +988,7 @@ ftdm_status_t encode_subAddrIE_nsap(const char *subAddr, char *subAddrIE, int ty
/* confirm it is a digit */
/* confirm it is a digit */
if
(
!
isdigit
(
tmp
[
0
]))
{
if
(
!
isdigit
(
tmp
[
0
]))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
/* move to the next character in subAddr */
/* move to the next character in subAddr */
x
++
;
x
++
;
...
@@ -1068,6 +1073,7 @@ ftdm_status_t encode_subAddrIE_nat(const char *subAddr, char *subAddrIE, int typ
...
@@ -1068,6 +1073,7 @@ ftdm_status_t encode_subAddrIE_nat(const char *subAddr, char *subAddrIE, int typ
/* confirm it is a hex digit */
/* confirm it is a hex digit */
while
((
!
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
while
((
!
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
/* move to the next character in subAddr */
/* move to the next character in subAddr */
x
++
;
x
++
;
tmp
[
0
]
=
subAddr
[
x
];
tmp
[
0
]
=
subAddr
[
x
];
...
@@ -1084,6 +1090,7 @@ ftdm_status_t encode_subAddrIE_nat(const char *subAddr, char *subAddrIE, int typ
...
@@ -1084,6 +1090,7 @@ ftdm_status_t encode_subAddrIE_nat(const char *subAddr, char *subAddrIE, int typ
/* check if the digit is a hex digit and that is not null */
/* check if the digit is a hex digit and that is not null */
while
(
!
(
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
while
(
!
(
isxdigit
(
tmp
[
0
]))
&&
(
tmp
[
0
]
!=
'\0'
))
{
SS7_INFO
(
"Dropping invalid digit: %c
\n
"
,
tmp
[
0
]);
x
++
;
x
++
;
tmp
[
0
]
=
subAddr
[
x
];
tmp
[
0
]
=
subAddr
[
x
];
}
/* while(!(isdigit(tmp))) */
}
/* while(!(isdigit(tmp))) */
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论