Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
8333afcb
提交
8333afcb
authored
1月 30, 2009
作者:
Helmut Kuper
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Q931ToPcap patch
git-svn-id:
http://svn.openzap.org/svn/openzap/trunk@628
a93c3328-9c30-0410-af19-c9cd2b2d52af
上级
ac172da1
全部展开
显示空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
977 行增加
和
322 行删除
+977
-322
Makefile.in
libs/openzap/Makefile.in
+7
-0
config.guess
libs/openzap/build/config.guess
+416
-255
config.sub
libs/openzap/build/config.sub
+198
-42
ltmain.sh
libs/openzap/build/ltmain.sh
+46
-13
mod_openzap.c
libs/openzap/mod_openzap/mod_openzap.c
+60
-9
ozmod_isdn.c
libs/openzap/src/ozmod/ozmod_isdn/ozmod_isdn.c
+250
-3
没有找到文件。
libs/openzap/Makefile.in
浏览文件 @
8333afcb
...
...
@@ -34,6 +34,11 @@ CPP = @CPP@
CPPFLAGS
=
@CPPFLAGS@
DEFS
=
@DEFS@
CFLAGS
=
@CFLAGS@ @COMP_VENDOR_CFLAGS@ @DEFS@
###For libpcap
CFLAGS
+=
-D_GNU_SOURCE
####
LIBS
=
@LIBS@
DYNAMIC_LIB_EXTEN
=
@DYNAMIC_LIB_EXTEN@
SOLINK
=
@SOLINK@
...
...
@@ -270,6 +275,8 @@ $(SRC)/ozmod/ozmod_isdn/ozmod_isdn.$(DYNAMIC_LIB_EXTEN): $(MYLIB) $(ISDN_OBJS) $
$(LINK)
$(SOLINK)
$(ISDN_OBJS)
$(SRC)
/ozmod/ozmod_isdn/ozmod_isdn.o
$(MYLIB)
-rpath
$(libdir)
isdnmod
:
$(SRC)/ozmod/ozmod_isdn/ozmod_isdn.$(DYNAMIC_LIB_EXTEN)
$(ISDN_OBJS2)
:
$(ISDN_HEADERS) $(ISDN_SOURCES) $(SRC)/ozmod/ozmod_isdn_libpcap/ozmod_isdn.c
$(SRC)/ozmod/ozmod_analog/ozmod_analog.$(DYNAMIC_LIB_EXTEN)
:
$(MYLIB) $(SRC)/ozmod/ozmod_analog/ozmod_analog.o
$(LINK)
$(SOLINK)
$(SRC)
/ozmod/ozmod_analog/ozmod_analog.o
$(MYLIB)
-rpath
$(libdir)
analogmod
:
$(SRC)/ozmod/ozmod_analog/ozmod_analog.$(DYNAMIC_LIB_EXTEN)
...
...
libs/openzap/build/config.guess
浏览文件 @
8333afcb
差异被折叠。
点击展开。
libs/openzap/build/config.sub
浏览文件 @
8333afcb
差异被折叠。
点击展开。
libs/openzap/build/ltmain.sh
浏览文件 @
8333afcb
...
...
@@ -113,7 +113,8 @@ esac
# These must not be set unconditionally because not all systems understand
# e.g. LANG=C (notably SCO).
# We save the old values to restore during execute mode.
for
lt_var
in
LANG LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
lt_env
=
for
lt_var
in
LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
do
eval
"if test
\"\$
{
$lt_var
+set}
\"
= set; then
save_
$lt_var
=
\$
$lt_var
...
...
@@ -122,6 +123,10 @@ do
fi"
done
if
test
-n
"
$lt_env
"
;
then
lt_env
=
"env
$lt_env
"
fi
# Make sure IFS has a sensible default
lt_nl
=
'
'
...
...
@@ -817,6 +822,7 @@ if test -z "$show_help"; then
*
.for
)
xform
=
for
;;
*
.java
)
xform
=
java
;;
*
.obj
)
xform
=
obj
;;
*
.sx
)
xform
=
sx
;;
esac
libobj
=
`
$echo
"X
$libobj
"
|
$Xsed
-e
"s/
\.
$xform$/
.lo/"
`
...
...
@@ -985,7 +991,7 @@ EOF
$run
$rm
"
$lobj
"
"
$output_obj
"
$show
"
$command
"
if
$run
eval
"
$command
"
;
then
:
if
$run
eval
$lt_env
"
$command
"
;
then
:
else
test
-n
"
$output_obj
"
&&
$run
$rm
$removelist
exit
$EXIT_FAILURE
...
...
@@ -1057,7 +1063,7 @@ EOF
command
=
"
$command$suppress_output
"
$run
$rm
"
$obj
"
"
$output_obj
"
$show
"
$command
"
if
$run
eval
"
$command
"
;
then
:
if
$run
eval
$lt_env
"
$command
"
;
then
:
else
$run
$rm
$removelist
exit
$EXIT_FAILURE
...
...
@@ -1190,6 +1196,7 @@ EOF
thread_safe
=
no
vinfo
=
vinfo_number
=
no
single_module
=
"
${
wl
}
-single_module"
func_infer_tag
$base_compile
...
...
@@ -1676,6 +1683,11 @@ EOF
continue
;;
-multi_module
)
single_module
=
"
${
wl
}
-multi_module"
continue
;;
-module
)
module
=
yes
continue
...
...
@@ -2152,7 +2164,10 @@ EOF
case
$pass
in
dlopen
)
libs
=
"
$dlfiles
"
;;
dlpreopen
)
libs
=
"
$dlprefiles
"
;;
link
)
libs
=
"
$deplibs
%DEPLIBS%
$dependency_libs
"
;;
link
)
libs
=
"
$deplibs
%DEPLIBS%"
test
"X
$link_all_deplibs
"
!=
Xno
&&
libs
=
"
$libs
$dependency_libs
"
;;
esac
fi
if
test
"
$pass
"
=
dlopen
;
then
...
...
@@ -2202,7 +2217,12 @@ EOF
continue
fi
name
=
`
$echo
"X
$deplib
"
|
$Xsed
-e
's/^-l//'
`
for
searchdir
in
$newlib_search_path
$lib_search_path
$sys_lib_search_path
$shlib_search_path
;
do
if
test
"
$linkmode
"
=
lib
;
then
searchdirs
=
"
$newlib_search_path
$lib_search_path
$compiler_lib_search_dirs
$sys_lib_search_path
$shlib_search_path
"
else
searchdirs
=
"
$newlib_search_path
$lib_search_path
$sys_lib_search_path
$shlib_search_path
"
fi
for
searchdir
in
$searchdirs
;
do
for
search_ext
in
.la
$std_shrext
.so .a
;
do
# Search the libtool library
lib
=
"
$searchdir
/lib
${
name
}${
search_ext
}
"
...
...
@@ -2998,12 +3018,18 @@ EOF
# we do not want to link against static libs,
# but need to link against shared
eval
deplibrary_names
=
`
${
SED
}
-n
-e
's/^library_names=\(.*\)$/\1/p'
$deplib
`
eval
deplibdir
=
`
${
SED
}
-n
-e
's/^libdir=\(.*\)$/\1/p'
$deplib
`
if
test
-n
"
$deplibrary_names
"
;
then
for
tmp
in
$deplibrary_names
;
do
depdepl
=
$tmp
done
if
test
-f
"
$path
/
$depdepl
"
;
then
if
test
-f
"
$deplibdir
/
$depdepl
"
;
then
depdepl
=
"
$deplibdir
/
$depdepl
"
elif
test
-f
"
$path
/
$depdepl
"
;
then
depdepl
=
"
$path
/
$depdepl
"
else
# Can't find it, oh well...
depdepl
=
fi
# do not add paths which are already there
case
"
$newlib_search_path
"
in
...
...
@@ -3151,9 +3177,10 @@ EOF
case
$linkmode
in
oldlib
)
if
test
-n
"
$deplibs
"
;
then
$echo
"
$modename
: warning:
\`
-l' and
\`
-L' are ignored for archives"
1>&2
fi
case
"
$deplibs
"
in
*
\
-l
*
|
*
\
-L
*
)
$echo
"
$modename
: warning:
\`
-l' and
\`
-L' are ignored for archives"
1>&2
;;
esac
if
test
-n
"
$dlfiles$dlprefiles
"
||
test
"
$dlself
"
!=
no
;
then
$echo
"
$modename
: warning:
\`
-dlopen' is ignored for archives"
1>&2
...
...
@@ -3297,6 +3324,11 @@ EOF
revision
=
"
$number_minor
"
lt_irix_increment
=
no
;;
*
)
$echo
"
$modename
: unknown library version type
\`
$version_type
'"
1>&2
$echo
"Fatal configuration error. See the
$PACKAGE
docs for more information."
1>&2
exit
$EXIT_FAILURE
;;
esac
;;
no
)
...
...
@@ -4290,9 +4322,10 @@ EOF
;;
obj
)
if
test
-n
"
$deplibs
"
;
then
$echo
"
$modename
: warning:
\`
-l' and
\`
-L' are ignored for objects"
1>&2
fi
case
"
$deplibs
"
in
*
\
-l
*
|
*
\
-L
*
)
$echo
"
$modename
: warning:
\`
-l' and
\`
-L' are ignored for objects"
1>&2
;;
esac
if
test
-n
"
$dlfiles$dlprefiles
"
||
test
"
$dlself
"
!=
no
;
then
$echo
"
$modename
: warning:
\`
-dlopen' is ignored for objects"
1>&2
...
...
@@ -6534,7 +6567,7 @@ relink_command=\"$relink_command\""
fi
# Restore saved environment variables
for
lt_var
in
LANG LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
for
lt_var
in
LANG L
ANGUAGE L
C_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
do
eval
"if test
\"\$
{save_
$lt_var
+set}
\"
= set; then
$lt_var
=
\$
save_
$lt_var
; export
$lt_var
...
...
libs/openzap/mod_openzap/mod_openzap.c
浏览文件 @
8333afcb
...
...
@@ -1682,6 +1682,7 @@ static switch_status_t load_config(void)
zap_log
(
ZAP_LOG_ERROR
,
"Error starting OpenZAP span %d
\n
"
,
span_id
);
continue
;
}
zap_log
(
ZAP_LOG_ERROR
,
"SPANID = %i
\n
"
,
span
->
span_id
);
SPAN_CONFIG
[
span
->
span_id
].
span
=
span
;
switch_set_string
(
SPAN_CONFIG
[
span
->
span_id
].
context
,
context
);
...
...
@@ -1838,7 +1839,7 @@ static switch_status_t load_config(void)
int
q921loglevel
=
-
1
;
int
q931loglevel
=
-
1
;
// quick debug
//
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ID: '%s', Name:'%s'\n",id,name);
//switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ID: '%s', Name:'%s'\n",id,name);
for
(
param
=
switch_xml_child
(
myspan
,
"param"
);
param
;
param
=
param
->
next
)
{
char
*
var
=
(
char
*
)
switch_xml_attr_soft
(
param
,
"name"
);
...
...
@@ -2055,7 +2056,7 @@ void dump_chan(zap_span_t *span, uint32_t chan_id, switch_stream_handle_t *strea
);
}
#define OZ_SYNTAX "list || dump <span_id> [<chan_id>]
"
#define OZ_SYNTAX "list || dump <span_id> [<chan_id>]
|| bounce <span_id> [<chan_id>] || q931_pcap <span_id> on|off [pcapfilename without suffix]"
SWITCH_STANDARD_API
(
oz_function
)
{
char
*
mycmd
=
NULL
,
*
argv
[
10
]
=
{
0
};
...
...
@@ -2139,7 +2140,7 @@ SWITCH_STANDARD_API(oz_function)
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"bounce"
))
{
/* MSC testing "oz bounce" command */
if
(
argc
<
2
)
{
stream
->
write_function
(
stream
,
"-ERR Usage: oz
dump
<span_id> [<chan_id>]
\n
"
);
stream
->
write_function
(
stream
,
"-ERR Usage: oz
bounce
<span_id> [<chan_id>]
\n
"
);
goto
end
;
}
else
{
int32_t
span_id
,
chan_id
=
0
;
...
...
@@ -2169,9 +2170,59 @@ SWITCH_STANDARD_API(oz_function)
}
}
}
/*Q931ToPcap enhancement*/
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"q931_pcap"
))
{
int32_t
span_id
=
0
;
zap_span_t
*
span
;
char
*
pcapfn
=
NULL
;
char
*
tmp_path
=
NULL
;
if
(
argc
<
3
)
{
stream
->
write_function
(
stream
,
"-ERR Usage: oz q931_pcap <span_id> on|off [pcapfilename without suffix]
\n
"
);
goto
end
;
}
span_id
=
atoi
(
argv
[
1
]);
if
(
!
(
span_id
&&
(
span
=
SPAN_CONFIG
[
span_id
].
span
)))
{
stream
->
write_function
(
stream
,
"-ERR invalid span
\n
"
);
goto
end
;
}
/*Look for a given file name or use default file name*/
if
(
argc
>
3
)
{
if
(
argv
[
3
]){
pcapfn
=
argv
[
3
];
}
}
else
{
pcapfn
=
"q931"
;
}
/*Add log directory path to file name*/
tmp_path
=
switch_mprintf
(
"%s%s%s.pcap"
,
SWITCH_GLOBAL_dirs
.
log_dir
,
SWITCH_PATH_SEPARATOR
,
pcapfn
);
if
(
!
strcasecmp
(
argv
[
2
],
"on"
))
{
if
(
zap_configure_span
(
"isdn"
,
span
,
on_clear_channel_signal
,
"q931topcap"
,
1
,
"pcapfilename"
,
tmp_path
,
TAG_END
)
!=
ZAP_SUCCESS
)
{
zap_log
(
ZAP_LOG_WARNING
,
"Error couldn't (re-)enable Q931-To-Pcap!
\n
"
);
goto
end
;
}
else
{
stream
->
write_function
(
stream
,
"+OK
\n
"
);
}
}
else
if
(
!
strcasecmp
(
argv
[
2
],
"off"
))
{
if
(
zap_configure_span
(
"isdn"
,
span
,
on_clear_channel_signal
,
"q931topcap"
,
0
,
TAG_END
)
!=
ZAP_SUCCESS
)
{
zap_log
(
ZAP_LOG_ERROR
,
"Error couldn't enable Q931-To-Pcap!
\n
"
);
goto
end
;
}
else
{
stream
->
write_function
(
stream
,
"+OK
\n
"
);
}
}
else
{
stream
->
write_function
(
stream
,
"-ERR Usage: oz q931_pcap on|off [pcapfilename without suffix]
\n
"
);
goto
end
;
}
}
else
{
stream
->
write_function
(
stream
,
"-ERR Usage:
oz list || dump <span_id> [<chan_id>]
\n
"
);
stream
->
write_function
(
stream
,
"-ERR Usage:
%s
\n
"
,
OZ_SYNTAX
);
}
/*Q931ToPcap enhancement done*/
end
:
...
...
libs/openzap/src/ozmod/ozmod_isdn/ozmod_isdn.c
浏览文件 @
8333afcb
差异被折叠。
点击展开。
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论