Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
29bf9157
提交
29bf9157
authored
5月 11, 2011
作者:
Anthony Minessale
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
clean up core curl patch
上级
d98d51ed
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
81 行增加
和
4 行删除
+81
-4
Makefile.am
Makefile.am
+4
-0
configure.in
configure.in
+5
-0
switch_curl.h
src/include/switch_curl.h
+55
-1
switch_curl.c
src/switch_curl.c
+17
-3
没有找到文件。
Makefile.am
浏览文件 @
29bf9157
...
...
@@ -104,6 +104,10 @@ CORE_CFLAGS += -I$(switch_srcdir)/libs/srtp/include
CORE_CFLAGS
+=
-I
$(switch_srcdir)
/libs/srtp/crypto/include
-Ilibs
/srtp/crypto/include
CORE_CFLAGS
+=
-I
$(switch_srcdir)
/libs/spandsp/src
-I
$(switch_srcdir)
/libs/tiff-3.8.2/libtiff
if
ENABLE_CORE_CURL
CORE_CFLAGS
+=
-DCORE_USE_CURL
endif
CORE_LIBS
=
libs/apr-util/libaprutil-1.la libs/apr/libapr-1.la
CORE_LIBS
+=
libs/sqlite/libsqlite3.la libs/pcre/libpcre.la libs/speex/libspeex/libspeexdsp.la
if
ENABLE_SRTP
...
...
configure.in
浏览文件 @
29bf9157
...
...
@@ -352,6 +352,11 @@ AC_ARG_ENABLE(srtp,
AM_CONDITIONAL([ENABLE_SRTP],[test "${enable_srtp}" = "yes"])
AC_ARG_ENABLE(core-curl,
[AC_HELP_STRING([--disable-core-curl],[build without core-curl support])],[enable_core_curl="$enableval"],[enable_core_curl="yes"])
AM_CONDITIONAL([ENABLE_CORE_CURL],[test "${enable_core_curl}" = "yes"])
AC_ARG_ENABLE(zrtp,
[AS_HELP_STRING([--enable-zrtp], [Compile with zrtp Support])],,[enable_zrtp="no"])
if test "x$enable_zrtp" = "xyes" ; then
...
...
src/include/switch_curl.h
浏览文件 @
29bf9157
/*
* FreeSWITCH Modular Media Switching Software Library / Soft-Switch Application
* Copyright (C) 2005-2011, Anthony Minessale II <anthm@freeswitch.org>
*
* Version: MPL 1.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is FreeSWITCH Modular Media Switching Software Library / Soft-Switch Application
*
* The Initial Developer of the Original Code is
* Anthony Minessale II <anthm@freeswitch.org>
* Portions created by the Initial Developer are Copyright (C)
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Anthony Minessale II <anthm@freeswitch.org>
*
*
* switch_curl.h -- Core cURL
*
*/
/*! \file switch_core.h
\brief Core Library
This module is the main core library and is the intended location of all fundamental operations.
*/
#ifndef SWITCH_CURL_H
#define SWITCH_CURL_H
SWITCH_BEGIN_EXTERN_C
void
switch_curl_init
(
switch_memory_pool_t
*
pool
);
void
switch_curl_destroy
();
void
switch_curl_destroy
(
void
);
SWITCH_END_EXTERN_C
#endif
/* For Emacs:
* Local Variables:
* mode:c
* indent-tabs-mode:t
* tab-width:4
* c-basic-offset:4
* End:
* For VIM:
* vim:set softtabstop=4 shiftwidth=4 tabstop=4:
*/
src/switch_curl.c
浏览文件 @
29bf9157
...
...
@@ -28,8 +28,9 @@
*
*/
#include <switch.h>
#ifdef CORE_USE_CURL
#include <openssl/crypto.h>
#include <curl/curl.h>
...
...
@@ -79,17 +80,30 @@ static void switch_curl_destroy_ssl_locks()
}
void
switch_curl_init
(
switch_memory_pool_t
*
pool
)
SWITCH_DECLARE
(
void
)
switch_curl_init
(
switch_memory_pool_t
*
pool
)
{
curl_global_init
(
CURL_GLOBAL_ALL
);
switch_curl_init_ssl_locks
(
pool
);
}
void
switch_curl_destroy
()
SWITCH_DECLARE
(
void
)
switch_curl_destroy
()
{
switch_curl_destroy_ssl_locks
();
curl_global_cleanup
();
}
#else
SWITCH_DECLARE
(
void
)
switch_curl_init
(
switch_memory_pool_t
*
pool
)
{
return
;
}
SWITCH_DECLARE
(
void
)
switch_curl_destroy
()
{
return
;
}
#endif
/* For Emacs:
* Local Variables:
* mode:c
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论