Merge branch 'signalwire:master' into mod_callcenter-pre-answer-incoming-member
This commit is contained in:
commit
7aece4ae84
|
@ -8,7 +8,7 @@ Visit [https://signalwire.com](https://signalwire.com/) or https://github.com/
|
||||||
|
|
||||||
FreeSWITCH is available on [Github](https://github.com/signalwire/freeswitch) in source code format. You can checkout the development branch and build for many popular platforms including Linux, Windows, MacOSX and BSD. There is an issue tracker and pull request system available as part of the repo online.
|
FreeSWITCH is available on [Github](https://github.com/signalwire/freeswitch) in source code format. You can checkout the development branch and build for many popular platforms including Linux, Windows, MacOSX and BSD. There is an issue tracker and pull request system available as part of the repo online.
|
||||||
|
|
||||||
See [https://freeswitch.com/#getting-started](https://freeswitch.com/#getting-started) for more detailed instructions.
|
See https://developer.signalwire.com/freeswitch/FreeSWITCH-Explained/ for more detailed instructions.
|
||||||
|
|
||||||
## Additional Help
|
## Additional Help
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
# Security Policy
|
||||||
|
|
||||||
|
## Reporting a Vulnerability
|
||||||
|
|
||||||
|
Send an e-mail to security@signalwire.com to report a vulnerability. If accepted, we'll create a security advisory and add you and your team as collaborators. Please allow our team sufficient time to resolve the vulnerability before disclosing it; we'll remain in contact about the fix and may ask for your assistance to verify it is resolved.
|
|
@ -1 +1 @@
|
||||||
1.10.9-dev
|
1.10.10-dev
|
||||||
|
|
|
@ -137,13 +137,13 @@
|
||||||
By default without specifying any crypto suites FreeSWITCH will offer
|
By default without specifying any crypto suites FreeSWITCH will offer
|
||||||
crypto suites from strongest to weakest accepting the strongest each
|
crypto suites from strongest to weakest accepting the strongest each
|
||||||
endpoint has in common. If you wish to force specific crypto suites you
|
endpoint has in common. If you wish to force specific crypto suites you
|
||||||
can do so by appending the suites in a comma separated list in the order
|
can do so by appending the suites in a colon separated list in the order
|
||||||
that you wish to offer them in.
|
that you wish to offer them in.
|
||||||
|
|
||||||
Examples:
|
Examples:
|
||||||
|
|
||||||
rtp_secure_media=mandatory:AES_CM_256_HMAC_SHA1_80,AES_CM_256_HMAC_SHA1_32
|
rtp_secure_media=mandatory:AES_CM_256_HMAC_SHA1_80:AES_CM_256_HMAC_SHA1_32
|
||||||
rtp_secure_media=true:AES_CM_256_HMAC_SHA1_80,AES_CM_256_HMAC_SHA1_32
|
rtp_secure_media=true:AES_CM_256_HMAC_SHA1_80:AES_CM_256_HMAC_SHA1_32
|
||||||
rtp_secure_media=optional:AES_CM_256_HMAC_SHA1_80
|
rtp_secure_media=optional:AES_CM_256_HMAC_SHA1_80
|
||||||
rtp_secure_media=true:AES_CM_256_HMAC_SHA1_80
|
rtp_secure_media=true:AES_CM_256_HMAC_SHA1_80
|
||||||
|
|
||||||
|
|
|
@ -3,10 +3,10 @@
|
||||||
|
|
||||||
# Must change all of the below together
|
# Must change all of the below together
|
||||||
# For a release, set revision for that tagged release as well and uncomment
|
# For a release, set revision for that tagged release as well and uncomment
|
||||||
AC_INIT([freeswitch], [1.10.9-dev], bugs@freeswitch.org)
|
AC_INIT([freeswitch], [1.10.10-dev], bugs@freeswitch.org)
|
||||||
AC_SUBST(SWITCH_VERSION_MAJOR, [1])
|
AC_SUBST(SWITCH_VERSION_MAJOR, [1])
|
||||||
AC_SUBST(SWITCH_VERSION_MINOR, [10])
|
AC_SUBST(SWITCH_VERSION_MINOR, [10])
|
||||||
AC_SUBST(SWITCH_VERSION_MICRO, [9-dev])
|
AC_SUBST(SWITCH_VERSION_MICRO, [10-dev])
|
||||||
AC_SUBST(SWITCH_VERSION_REVISION, [])
|
AC_SUBST(SWITCH_VERSION_REVISION, [])
|
||||||
AC_SUBST(SWITCH_VERSION_REVISION_HUMAN, [])
|
AC_SUBST(SWITCH_VERSION_REVISION_HUMAN, [])
|
||||||
|
|
||||||
|
@ -716,7 +716,7 @@ PKG_CHECK_MODULES([SPANDSP], [spandsp >= 3.0],[
|
||||||
AC_MSG_ERROR([no usable spandsp; please install spandsp3 devel package or equivalent])
|
AC_MSG_ERROR([no usable spandsp; please install spandsp3 devel package or equivalent])
|
||||||
])
|
])
|
||||||
|
|
||||||
PKG_CHECK_MODULES([SOFIA_SIP], [sofia-sip-ua >= 1.13.6],[
|
PKG_CHECK_MODULES([SOFIA_SIP], [sofia-sip-ua >= 1.13.14],[
|
||||||
AM_CONDITIONAL([HAVE_SOFIA_SIP],[true])],[
|
AM_CONDITIONAL([HAVE_SOFIA_SIP],[true])],[
|
||||||
AC_MSG_ERROR([no usable sofia-sip; please install sofia-sip-ua devel package or equivalent])
|
AC_MSG_ERROR([no usable sofia-sip; please install sofia-sip-ua devel package or equivalent])
|
||||||
])
|
])
|
||||||
|
@ -1518,7 +1518,7 @@ PKG_CHECK_MODULES([V8FS_STATIC], [v8-6.1_static >= 6.1.298],[
|
||||||
])
|
])
|
||||||
])
|
])
|
||||||
|
|
||||||
PKG_CHECK_MODULES([KS], [libks >= 1.1.0],[
|
PKG_CHECK_MODULES([KS], [libks >= 1.8.2],[
|
||||||
AM_CONDITIONAL([HAVE_KS],[true])],[
|
AM_CONDITIONAL([HAVE_KS],[true])],[
|
||||||
if module_enabled mod_verto; then
|
if module_enabled mod_verto; then
|
||||||
AC_MSG_ERROR([You need to either install libks or disable mod_verto in modules.conf])
|
AC_MSG_ERROR([You need to either install libks or disable mod_verto in modules.conf])
|
||||||
|
|
|
@ -332,7 +332,7 @@ Build-Depends:
|
||||||
uuid-dev, libexpat1-dev, libgdbm-dev, libdb-dev,
|
uuid-dev, libexpat1-dev, libgdbm-dev, libdb-dev,
|
||||||
# used by many modules
|
# used by many modules
|
||||||
libcurl4-openssl-dev | libcurl4-gnutls-dev | libcurl-dev,
|
libcurl4-openssl-dev | libcurl4-gnutls-dev | libcurl-dev,
|
||||||
bison, zlib1g-dev, libsofia-sip-ua-dev (>= 1.13.6),
|
bison, zlib1g-dev, libsofia-sip-ua-dev (>= 1.13.14),
|
||||||
libspandsp3-dev,
|
libspandsp3-dev,
|
||||||
# used to format the private freeswitch apt-repo key properly
|
# used to format the private freeswitch apt-repo key properly
|
||||||
gnupg,
|
gnupg,
|
||||||
|
@ -371,7 +371,7 @@ Description: Cross-Platform Scalable Multi-Protocol Soft Switch
|
||||||
|
|
||||||
Package: libfreeswitch1
|
Package: libfreeswitch1
|
||||||
Architecture: amd64 armhf
|
Architecture: amd64 armhf
|
||||||
Depends: \${shlibs:Depends}, \${misc:Depends}, libsofia-sip-ua0 (>= 1.13.6)
|
Depends: \${shlibs:Depends}, \${misc:Depends}, libsofia-sip-ua0 (>= 1.13.14)
|
||||||
Recommends:
|
Recommends:
|
||||||
Suggests: libfreeswitch1-dbg
|
Suggests: libfreeswitch1-dbg
|
||||||
Conflicts: freeswitch-all (<= 1.6.7)
|
Conflicts: freeswitch-all (<= 1.6.7)
|
||||||
|
|
|
@ -31,13 +31,18 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get -yq install \
|
||||||
# mod_pgsql
|
# mod_pgsql
|
||||||
libpq-dev \
|
libpq-dev \
|
||||||
# mod_sndfile
|
# mod_sndfile
|
||||||
libsndfile1-dev libflac-dev libogg-dev libvorbis-dev
|
libsndfile1-dev libflac-dev libogg-dev libvorbis-dev \
|
||||||
|
# mod_shout
|
||||||
|
libshout3-dev libmpg123-dev libmp3lame-dev
|
||||||
|
|
||||||
RUN cd /usr/src/libs/libks && cmake . -DCMAKE_INSTALL_PREFIX=/usr -DWITH_LIBBACKTRACE=1 && make install
|
RUN cd /usr/src/libs/libks && cmake . -DCMAKE_INSTALL_PREFIX=/usr -DWITH_LIBBACKTRACE=1 && make install
|
||||||
RUN cd /usr/src/libs/sofia-sip && ./bootstrap.sh && ./configure CFLAGS="-g -ggdb" --with-pic --with-glib=no --without-doxygen --disable-stun --prefix=/usr && make -j`nproc --all` && make install
|
RUN cd /usr/src/libs/sofia-sip && ./bootstrap.sh && ./configure CFLAGS="-g -ggdb" --with-pic --with-glib=no --without-doxygen --disable-stun --prefix=/usr && make -j`nproc --all` && make install
|
||||||
RUN cd /usr/src/libs/spandsp && ./bootstrap.sh && ./configure CFLAGS="-g -ggdb" --with-pic --prefix=/usr && make -j`nproc --all` && make install
|
RUN cd /usr/src/libs/spandsp && ./bootstrap.sh && ./configure CFLAGS="-g -ggdb" --with-pic --prefix=/usr && make -j`nproc --all` && make install
|
||||||
RUN cd /usr/src/libs/signalwire-c && PKG_CONFIG_PATH=/usr/lib/pkgconfig cmake . -DCMAKE_INSTALL_PREFIX=/usr && make install
|
RUN cd /usr/src/libs/signalwire-c && PKG_CONFIG_PATH=/usr/lib/pkgconfig cmake . -DCMAKE_INSTALL_PREFIX=/usr && make install
|
||||||
|
|
||||||
|
# Enable modules
|
||||||
|
RUN sed -i 's|#formats/mod_shout|formats/mod_shout|' /usr/src/freeswitch/build/modules.conf.in
|
||||||
|
|
||||||
RUN cd /usr/src/freeswitch && ./bootstrap.sh -j
|
RUN cd /usr/src/freeswitch && ./bootstrap.sh -j
|
||||||
RUN cd /usr/src/freeswitch && ./configure
|
RUN cd /usr/src/freeswitch && ./configure
|
||||||
RUN cd /usr/src/freeswitch && make -j`nproc` && make install
|
RUN cd /usr/src/freeswitch && make -j`nproc` && make install
|
||||||
|
@ -46,4 +51,4 @@ RUN cd /usr/src/freeswitch && make -j`nproc` && make install
|
||||||
RUN apt-get clean
|
RUN apt-get clean
|
||||||
|
|
||||||
# Uncomment to cleanup even more
|
# Uncomment to cleanup even more
|
||||||
#RUN rm -rf /usr/src/*
|
#RUN rm -rf /usr/src/*
|
||||||
|
|
|
@ -140,7 +140,7 @@ BuildRequires: curl-devel >= 7.19
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
BuildRequires: libtool >= 1.5.17
|
BuildRequires: libtool >= 1.5.17
|
||||||
BuildRequires: openssl-devel >= 1.0.1e
|
BuildRequires: openssl-devel >= 1.0.1e
|
||||||
BuildRequires: sofia-sip-devel >= 1.13.6
|
BuildRequires: sofia-sip-devel >= 1.13.14
|
||||||
BuildRequires: spandsp3-devel >= 3.0
|
BuildRequires: spandsp3-devel >= 3.0
|
||||||
BuildRequires: pcre-devel
|
BuildRequires: pcre-devel
|
||||||
BuildRequires: speex-devel
|
BuildRequires: speex-devel
|
||||||
|
|
|
@ -617,6 +617,7 @@ srtp/build/compile
|
||||||
/curl-*/
|
/curl-*/
|
||||||
/sqlite-*.zip
|
/sqlite-*.zip
|
||||||
/sqlite-*/
|
/sqlite-*/
|
||||||
|
/sqlite/
|
||||||
/ldns/
|
/ldns/
|
||||||
/portaudio/
|
/portaudio/
|
||||||
portaudio.*.log
|
portaudio.*.log
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
#include "fspr_pools.h"
|
#include "fspr_pools.h"
|
||||||
#include "fspr_errno.h"
|
#include "fspr_errno.h"
|
||||||
|
|
||||||
#if !defined(_ANSI_SOURCE) && defined(_DARWIN_C_SOURCE)
|
#if !defined(NSIG) && !defined(_ANSI_SOURCE) && defined(_DARWIN_C_SOURCE)
|
||||||
#define NSIG __DARWIN_NSIG
|
#define NSIG __DARWIN_NSIG
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -323,10 +323,10 @@
|
||||||
</PostBuildEvent>
|
</PostBuildEvent>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="..\..\sqlite-amalgamation-3080401\sqlite3.c" />
|
<ClCompile Include="..\..\sqlite\sqlite3.c" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="..\..\sqlite-amalgamation-3080401\sqlite3.h" />
|
<ClInclude Include="..\..\sqlite\sqlite3.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||||
<ImportGroup Label="ExtensionTargets">
|
<ImportGroup Label="ExtensionTargets">
|
||||||
|
|
|
@ -23,7 +23,7 @@ if HAVE_STIRSHAKEN
|
||||||
test_test_sofia_funcs_CFLAGS += -DHAVE_STIRSHAKEN
|
test_test_sofia_funcs_CFLAGS += -DHAVE_STIRSHAKEN
|
||||||
endif
|
endif
|
||||||
test_test_sofia_funcs_LDFLAGS = $(AM_LDFLAGS) -avoid-version -no-undefined $(freeswitch_LDFLAGS) $(switch_builddir)/libfreeswitch.la $(CORE_LIBS) $(APR_LIBS) $(STIRSHAKEN_LIBS)
|
test_test_sofia_funcs_LDFLAGS = $(AM_LDFLAGS) -avoid-version -no-undefined $(freeswitch_LDFLAGS) $(switch_builddir)/libfreeswitch.la $(CORE_LIBS) $(APR_LIBS) $(STIRSHAKEN_LIBS)
|
||||||
test_test_sofia_funcs_LDADD = libsofiamod.la $(SOFIA_SIP_LIBS)
|
test_test_sofia_funcs_LDADD = libsofiamod.la $(SOFIA_SIP_LIBS) $(STIRSHAKEN_LIBS)
|
||||||
|
|
||||||
test_test_nuafail_SOURCES = test/test_nuafail.c
|
test_test_nuafail_SOURCES = test/test_nuafail.c
|
||||||
test_test_nuafail_CFLAGS = $(AM_CFLAGS) $(SOFIA_SIP_CFLAGS) $(STIRSHAKEN_CFLAGS) -DSWITCH_TEST_BASE_DIR_FOR_CONF=\"${abs_builddir}/test\" -DSWITCH_TEST_BASE_DIR_OVERRIDE=\"${abs_builddir}/test\"
|
test_test_nuafail_CFLAGS = $(AM_CFLAGS) $(SOFIA_SIP_CFLAGS) $(STIRSHAKEN_CFLAGS) -DSWITCH_TEST_BASE_DIR_FOR_CONF=\"${abs_builddir}/test\" -DSWITCH_TEST_BASE_DIR_OVERRIDE=\"${abs_builddir}/test\"
|
||||||
|
|
|
@ -2065,7 +2065,8 @@ static switch_status_t sofia_receive_message(switch_core_session_t *session, swi
|
||||||
|
|
||||||
nua_info(tech_pvt->nh, SIPTAG_CONTENT_TYPE_STR("message/sipfrag"),
|
nua_info(tech_pvt->nh, SIPTAG_CONTENT_TYPE_STR("message/sipfrag"),
|
||||||
TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)), SIPTAG_PAYLOAD_STR(message), TAG_END());
|
TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)), SIPTAG_PAYLOAD_STR(message), TAG_END());
|
||||||
} else if (update_allowed && ua && (switch_stristr("polycom", ua) ||
|
} else if (update_allowed && ua && (switch_channel_var_true(tech_pvt->channel, "update_ignore_ua") ||
|
||||||
|
switch_stristr("polycom", ua) ||
|
||||||
(switch_stristr("aastra", ua) && !switch_stristr("Intelligate", ua)) ||
|
(switch_stristr("aastra", ua) && !switch_stristr("Intelligate", ua)) ||
|
||||||
(switch_stristr("cisco/spa50", ua) ||
|
(switch_stristr("cisco/spa50", ua) ||
|
||||||
switch_stristr("cisco/spa525", ua)) ||
|
switch_stristr("cisco/spa525", ua)) ||
|
||||||
|
@ -4667,7 +4668,7 @@ static switch_status_t sofia_manage(char *relative_oid, switch_management_action
|
||||||
return SWITCH_STATUS_SUCCESS;
|
return SWITCH_STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int protect_dest_uri(switch_caller_profile_t *cp)
|
int protect_dest_uri(switch_caller_profile_t *cp)
|
||||||
{
|
{
|
||||||
char *p = cp->destination_number, *o = p;
|
char *p = cp->destination_number, *o = p;
|
||||||
char *q = NULL, *e = NULL, *qenc = NULL;
|
char *q = NULL, *e = NULL, *qenc = NULL;
|
||||||
|
|
|
@ -11484,6 +11484,16 @@ void sofia_handle_sip_i_invite(switch_core_session_t *session, nua_t *nua, sofia
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (sip->sip_identity) {
|
||||||
|
sip_identity_t *id;
|
||||||
|
|
||||||
|
for (id = sip->sip_identity; id; id = id->id_next) {
|
||||||
|
if (!zstr(id->id_value)) {
|
||||||
|
switch_channel_add_variable_var_check(channel, "sip_identity", id->id_value, SWITCH_FALSE, SWITCH_STACK_PUSH);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (sip->sip_identity && sip->sip_identity->id_value) {
|
if (sip->sip_identity && sip->sip_identity->id_value) {
|
||||||
switch_channel_set_variable(channel, "sip_h_identity", sip->sip_identity->id_value);
|
switch_channel_set_variable(channel, "sip_h_identity", sip->sip_identity->id_value);
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
|
|
||||||
#include <switch.h>
|
#include <switch.h>
|
||||||
#include <test/switch_test.h>
|
#include <test/switch_test.h>
|
||||||
#include "../mod_sofia.c"
|
|
||||||
|
int protect_dest_uri(switch_caller_profile_t *cp);
|
||||||
|
|
||||||
static int timeout_sec = 10;
|
static int timeout_sec = 10;
|
||||||
static switch_interval_time_t delay_start_ms = 5000;
|
static switch_interval_time_t delay_start_ms = 5000;
|
||||||
|
|
|
@ -1970,6 +1970,7 @@ static void client_run(jsock_t *jsock)
|
||||||
{
|
{
|
||||||
int flags = KWS_BLOCK;
|
int flags = KWS_BLOCK;
|
||||||
int idle = 0;
|
int idle = 0;
|
||||||
|
ks_json_t *params = NULL;
|
||||||
|
|
||||||
if (jsock->profile->vhosts) {
|
if (jsock->profile->vhosts) {
|
||||||
flags |= KWS_STAY_OPEN;
|
flags |= KWS_STAY_OPEN;
|
||||||
|
@ -1977,7 +1978,14 @@ static void client_run(jsock_t *jsock)
|
||||||
}
|
}
|
||||||
|
|
||||||
ks_pool_open(&jsock->kpool);
|
ks_pool_open(&jsock->kpool);
|
||||||
|
|
||||||
|
#if defined(KS_VERSION_NUM) && KS_VERSION_NUM >= 20000
|
||||||
|
params = ks_json_create_object();
|
||||||
|
ks_json_add_number_to_object(params, "payload_size_max", 1000000);
|
||||||
|
if (kws_init_ex(&jsock->ws, jsock->client_socket, (jsock->ptype & PTYPE_CLIENT_SSL) ? jsock->profile->ssl_ctx : NULL, 0, flags, jsock->kpool, params) != KS_STATUS_SUCCESS) {
|
||||||
|
#else
|
||||||
if (kws_init(&jsock->ws, jsock->client_socket, (jsock->ptype & PTYPE_CLIENT_SSL) ? jsock->profile->ssl_ctx : NULL, 0, flags, jsock->kpool) != KS_STATUS_SUCCESS) {
|
if (kws_init(&jsock->ws, jsock->client_socket, (jsock->ptype & PTYPE_CLIENT_SSL) ? jsock->profile->ssl_ctx : NULL, 0, flags, jsock->kpool) != KS_STATUS_SUCCESS) {
|
||||||
|
#endif
|
||||||
log_and_exit(SWITCH_LOG_NOTICE, "%s WS SETUP FAILED\n", jsock->name);
|
log_and_exit(SWITCH_LOG_NOTICE, "%s WS SETUP FAILED\n", jsock->name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2123,6 +2131,8 @@ static void client_run(jsock_t *jsock)
|
||||||
detach_jsock(jsock);
|
detach_jsock(jsock);
|
||||||
kws_destroy(&jsock->ws);
|
kws_destroy(&jsock->ws);
|
||||||
ks_pool_close(&jsock->kpool);
|
ks_pool_close(&jsock->kpool);
|
||||||
|
ks_json_delete(¶ms);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6769,6 +6779,10 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_verto_load)
|
||||||
ks_ssl_init_skip(KS_TRUE);
|
ks_ssl_init_skip(KS_TRUE);
|
||||||
ks_init();
|
ks_init();
|
||||||
|
|
||||||
|
#if defined(KS_VERSION_NUM) && KS_VERSION_NUM < 20000
|
||||||
|
kws_set_global_payload_size_max(1000000);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (switch_event_reserve_subclass(MY_EVENT_LOGIN) != SWITCH_STATUS_SUCCESS) {
|
if (switch_event_reserve_subclass(MY_EVENT_LOGIN) != SWITCH_STATUS_SUCCESS) {
|
||||||
ks_shutdown();
|
ks_shutdown();
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Couldn't register subclass %s!\n", MY_EVENT_LOGIN);
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Couldn't register subclass %s!\n", MY_EVENT_LOGIN);
|
||||||
|
|
|
@ -70,6 +70,11 @@
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
|
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
<ItemDefinitionGroup>
|
||||||
|
<ClCompile>
|
||||||
|
<PreprocessorDefinitions>AMQP_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
|
</ClCompile>
|
||||||
|
</ItemDefinitionGroup>
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||||
<ClCompile>
|
<ClCompile>
|
||||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
|
|
|
@ -39405,6 +39405,24 @@ SWIGEXPORT int SWIGSTDCALL CSharp_FreeSWITCHfNative_switch_event_add_header_stri
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
SWIGEXPORT int SWIGSTDCALL CSharp_FreeSWITCHfNative_switch_event_add_header_string_nodup___(void * jarg1, int jarg2, char * jarg3, char * jarg4) {
|
||||||
|
int jresult ;
|
||||||
|
switch_event_t *arg1 = (switch_event_t *) 0 ;
|
||||||
|
switch_stack_t arg2 ;
|
||||||
|
char *arg3 = (char *) 0 ;
|
||||||
|
char *arg4 = (char *) 0 ;
|
||||||
|
switch_status_t result;
|
||||||
|
|
||||||
|
arg1 = (switch_event_t *)jarg1;
|
||||||
|
arg2 = (switch_stack_t)jarg2;
|
||||||
|
arg3 = (char *)jarg3;
|
||||||
|
arg4 = (char *)jarg4;
|
||||||
|
result = (switch_status_t)switch_event_add_header_string_nodup(arg1,arg2,(char const *)arg3,(char const *)arg4);
|
||||||
|
jresult = (int)result;
|
||||||
|
return jresult;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
SWIGEXPORT int SWIGSTDCALL CSharp_FreeSWITCHfNative_switch_event_del_header_val___(void * jarg1, char * jarg2, char * jarg3) {
|
SWIGEXPORT int SWIGSTDCALL CSharp_FreeSWITCHfNative_switch_event_del_header_val___(void * jarg1, char * jarg2, char * jarg3) {
|
||||||
int jresult ;
|
int jresult ;
|
||||||
switch_event_t *arg1 = (switch_event_t *) 0 ;
|
switch_event_t *arg1 = (switch_event_t *) 0 ;
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -167,9 +167,15 @@ void Session::do_hangup_hook()
|
||||||
arglist = Py_BuildValue("(Os)", Self, what);
|
arglist = Py_BuildValue("(Os)", Self, what);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if PY_VERSION_HEX <= 0x03080000
|
||||||
if (!PyEval_CallObject(hangup_func, arglist)) {
|
if (!PyEval_CallObject(hangup_func, arglist)) {
|
||||||
PyErr_Print();
|
PyErr_Print();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
if (!PyObject_CallObject(hangup_func, arglist)) {
|
||||||
|
PyErr_Print();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
Py_XDECREF(arglist);
|
Py_XDECREF(arglist);
|
||||||
Py_XDECREF(hangup_func_arg);
|
Py_XDECREF(hangup_func_arg);
|
||||||
|
@ -287,7 +293,7 @@ switch_status_t Session::run_dtmf_callback(void *input, switch_input_type_t ityp
|
||||||
|
|
||||||
PyObject *pyresult, *arglist, *io = NULL;
|
PyObject *pyresult, *arglist, *io = NULL;
|
||||||
int ts = 0;
|
int ts = 0;
|
||||||
char *str = NULL, *what = "";
|
char *str = NULL, *what = (char*)"";
|
||||||
|
|
||||||
if (TS) {
|
if (TS) {
|
||||||
ts++;
|
ts++;
|
||||||
|
@ -302,9 +308,9 @@ switch_status_t Session::run_dtmf_callback(void *input, switch_input_type_t ityp
|
||||||
if (itype == SWITCH_INPUT_TYPE_DTMF) {
|
if (itype == SWITCH_INPUT_TYPE_DTMF) {
|
||||||
switch_dtmf_t *dtmf = (switch_dtmf_t *) input;
|
switch_dtmf_t *dtmf = (switch_dtmf_t *) input;
|
||||||
io = mod_python_conjure_DTMF(dtmf->digit, dtmf->duration);
|
io = mod_python_conjure_DTMF(dtmf->digit, dtmf->duration);
|
||||||
what = "dtmf";
|
what = (char*)"dtmf";
|
||||||
} else if (itype == SWITCH_INPUT_TYPE_EVENT){
|
} else if (itype == SWITCH_INPUT_TYPE_EVENT){
|
||||||
what = "event";
|
what = (char*)"event";
|
||||||
io = mod_python_conjure_event((switch_event_t *) input);
|
io = mod_python_conjure_event((switch_event_t *) input);
|
||||||
} else {
|
} else {
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "unsupported type!\n");
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "unsupported type!\n");
|
||||||
|
@ -320,8 +326,12 @@ switch_status_t Session::run_dtmf_callback(void *input, switch_input_type_t ityp
|
||||||
} else {
|
} else {
|
||||||
arglist = Py_BuildValue("(OsO)", Self, what, io);
|
arglist = Py_BuildValue("(OsO)", Self, what, io);
|
||||||
}
|
}
|
||||||
|
#if PY_VERSION_HEX <= 0x03080000
|
||||||
if ((pyresult = PyEval_CallObject(cb_function, arglist))) {
|
pyresult = PyEval_CallObject(cb_function, arglist);
|
||||||
|
#else
|
||||||
|
pyresult = PyObject_CallObject(cb_function, arglist);
|
||||||
|
#endif
|
||||||
|
if (pyresult) {
|
||||||
str = (char *) PyString_AsString(pyresult);
|
str = (char *) PyString_AsString(pyresult);
|
||||||
} else {
|
} else {
|
||||||
PyErr_Print();
|
PyErr_Print();
|
||||||
|
|
|
@ -354,12 +354,24 @@ static switch_xml_t python_fetch(const char *section,
|
||||||
|
|
||||||
switch_xml_t xml = NULL;
|
switch_xml_t xml = NULL;
|
||||||
char *str = NULL;
|
char *str = NULL;
|
||||||
|
switch_event_t *my_params = NULL;
|
||||||
|
|
||||||
if (!zstr(globals.xml_handler)) {
|
if (!zstr(globals.xml_handler)) {
|
||||||
char *mycmd = strdup(globals.xml_handler);
|
char *mycmd = strdup(globals.xml_handler);
|
||||||
|
|
||||||
switch_assert(mycmd);
|
switch_assert(mycmd);
|
||||||
|
|
||||||
|
if (!params) {
|
||||||
|
switch_event_create(¶ms, SWITCH_EVENT_REQUEST_PARAMS);
|
||||||
|
switch_assert(params);
|
||||||
|
my_params = params;
|
||||||
|
}
|
||||||
|
|
||||||
|
switch_event_add_header_string(params, SWITCH_STACK_TOP, "section", switch_str_nil(section));
|
||||||
|
switch_event_add_header_string(params, SWITCH_STACK_TOP, "tag_name", switch_str_nil(tag_name));
|
||||||
|
switch_event_add_header_string(params, SWITCH_STACK_TOP, "key_name", switch_str_nil(key_name));
|
||||||
|
switch_event_add_header_string(params, SWITCH_STACK_TOP, "key_value", switch_str_nil(key_value));
|
||||||
|
|
||||||
eval_some_python("xml_fetch", mycmd, NULL, NULL, params, &str, NULL);
|
eval_some_python("xml_fetch", mycmd, NULL, NULL, params, &str, NULL);
|
||||||
|
|
||||||
if (str) {
|
if (str) {
|
||||||
|
@ -372,6 +384,10 @@ static switch_xml_t python_fetch(const char *section,
|
||||||
}
|
}
|
||||||
|
|
||||||
free(mycmd);
|
free(mycmd);
|
||||||
|
|
||||||
|
if (my_params) {
|
||||||
|
switch_event_destroy(&my_params);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return xml;
|
return xml;
|
||||||
|
|
|
@ -141,6 +141,7 @@ static size_t file_callback(void *ptr, size_t size, size_t nmemb, void *data)
|
||||||
static switch_xml_t xml_url_fetch(const char *section, const char *tag_name, const char *key_name, const char *key_value, switch_event_t *params,
|
static switch_xml_t xml_url_fetch(const char *section, const char *tag_name, const char *key_name, const char *key_value, switch_event_t *params,
|
||||||
void *user_data)
|
void *user_data)
|
||||||
{
|
{
|
||||||
|
switch_event_t *my_params = NULL;
|
||||||
char filename[512] = "";
|
char filename[512] = "";
|
||||||
switch_CURL *curl_handle = NULL;
|
switch_CURL *curl_handle = NULL;
|
||||||
switch_CURLcode cc;
|
switch_CURLcode cc;
|
||||||
|
@ -185,6 +186,7 @@ static switch_xml_t xml_url_fetch(const char *section, const char *tag_name, con
|
||||||
if (!params) {
|
if (!params) {
|
||||||
switch_event_create(¶ms, SWITCH_EVENT_REQUEST_PARAMS);
|
switch_event_create(¶ms, SWITCH_EVENT_REQUEST_PARAMS);
|
||||||
switch_assert(params);
|
switch_assert(params);
|
||||||
|
my_params = params;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch_event_add_header_string(params, SWITCH_STACK_TOP, "hostname", hostname);
|
switch_event_add_header_string(params, SWITCH_STACK_TOP, "hostname", hostname);
|
||||||
|
@ -333,6 +335,11 @@ static switch_xml_t xml_url_fetch(const char *section, const char *tag_name, con
|
||||||
switch_safe_free(uri);
|
switch_safe_free(uri);
|
||||||
if (binding->use_dynamic_url && dynamic_url != binding->url)
|
if (binding->use_dynamic_url && dynamic_url != binding->url)
|
||||||
switch_safe_free(dynamic_url);
|
switch_safe_free(dynamic_url);
|
||||||
|
|
||||||
|
if (my_params) {
|
||||||
|
switch_event_destroy(&my_params);
|
||||||
|
}
|
||||||
|
|
||||||
return xml;
|
return xml;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -837,7 +837,7 @@ SWITCH_DECLARE(unsigned char) switch_console_complete(const char *line, const ch
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (x = 0; x < argc && x < 11; x++) {
|
for (x = 0; x < argc; x++) {
|
||||||
if (h.words + 1 > argc) {
|
if (h.words + 1 > argc) {
|
||||||
if (switch_cache_db_get_type(db) == SCDB_TYPE_CORE_DB) {
|
if (switch_cache_db_get_type(db) == SCDB_TYPE_CORE_DB) {
|
||||||
stream.write_function(&stream, "(a%d like '::%%' or a%d = '' or a%d = '%q')%q",
|
stream.write_function(&stream, "(a%d like '::%%' or a%d = '' or a%d = '%q')%q",
|
||||||
|
|
|
@ -2380,11 +2380,6 @@ SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request_uuid(switch_
|
||||||
int32_t sps = 0;
|
int32_t sps = 0;
|
||||||
|
|
||||||
|
|
||||||
if (use_uuid && switch_core_hash_find(session_manager.session_table, use_uuid)) {
|
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Duplicate UUID!\n");
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (direction == SWITCH_CALL_DIRECTION_INBOUND && !switch_core_ready_inbound()) {
|
if (direction == SWITCH_CALL_DIRECTION_INBOUND && !switch_core_ready_inbound()) {
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "The system cannot create any inbound sessions at this time.\n");
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "The system cannot create any inbound sessions at this time.\n");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@ -2406,6 +2401,15 @@ SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request_uuid(switch_
|
||||||
|
|
||||||
PROTECT_INTERFACE(endpoint_interface);
|
PROTECT_INTERFACE(endpoint_interface);
|
||||||
|
|
||||||
|
switch_mutex_lock(runtime.session_hash_mutex);
|
||||||
|
if (use_uuid && switch_core_hash_find(session_manager.session_table, use_uuid)) {
|
||||||
|
switch_mutex_unlock(runtime.session_hash_mutex);
|
||||||
|
UNPROTECT_INTERFACE(endpoint_interface);
|
||||||
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Duplicate UUID!\n");
|
||||||
|
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
if (!(originate_flags & SOF_NO_LIMITS)) {
|
if (!(originate_flags & SOF_NO_LIMITS)) {
|
||||||
switch_mutex_lock(runtime.throttle_mutex);
|
switch_mutex_lock(runtime.throttle_mutex);
|
||||||
count = session_manager.session_count;
|
count = session_manager.session_count;
|
||||||
|
@ -2413,12 +2417,14 @@ SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request_uuid(switch_
|
||||||
switch_mutex_unlock(runtime.throttle_mutex);
|
switch_mutex_unlock(runtime.throttle_mutex);
|
||||||
|
|
||||||
if (sps <= 0) {
|
if (sps <= 0) {
|
||||||
|
switch_mutex_unlock(runtime.session_hash_mutex);
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Throttle Error! %d\n", session_manager.session_count);
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Throttle Error! %d\n", session_manager.session_count);
|
||||||
UNPROTECT_INTERFACE(endpoint_interface);
|
UNPROTECT_INTERFACE(endpoint_interface);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((count + 1) > session_manager.session_limit) {
|
if ((count + 1) > session_manager.session_limit) {
|
||||||
|
switch_mutex_unlock(runtime.session_hash_mutex);
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Over Session Limit! %d\n", session_manager.session_limit);
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Over Session Limit! %d\n", session_manager.session_limit);
|
||||||
UNPROTECT_INTERFACE(endpoint_interface);
|
UNPROTECT_INTERFACE(endpoint_interface);
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@ -2490,7 +2496,6 @@ SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request_uuid(switch_
|
||||||
switch_queue_create(&session->private_event_queue, SWITCH_EVENT_QUEUE_LEN, session->pool);
|
switch_queue_create(&session->private_event_queue, SWITCH_EVENT_QUEUE_LEN, session->pool);
|
||||||
switch_queue_create(&session->private_event_queue_pri, SWITCH_EVENT_QUEUE_LEN, session->pool);
|
switch_queue_create(&session->private_event_queue_pri, SWITCH_EVENT_QUEUE_LEN, session->pool);
|
||||||
|
|
||||||
switch_mutex_lock(runtime.session_hash_mutex);
|
|
||||||
switch_core_hash_insert(session_manager.session_table, session->uuid_str, session);
|
switch_core_hash_insert(session_manager.session_table, session->uuid_str, session);
|
||||||
session->id = session_manager.session_id++;
|
session->id = session_manager.session_id++;
|
||||||
session_manager.session_count++;
|
session_manager.session_count++;
|
||||||
|
|
|
@ -1465,6 +1465,7 @@ typedef struct {
|
||||||
int done;
|
int done;
|
||||||
switch_thread_t *thread;
|
switch_thread_t *thread;
|
||||||
switch_mutex_t *mutex;
|
switch_mutex_t *mutex;
|
||||||
|
switch_mutex_t *fence_mutex;
|
||||||
switch_dial_handle_t *dh;
|
switch_dial_handle_t *dh;
|
||||||
} enterprise_originate_handle_t;
|
} enterprise_originate_handle_t;
|
||||||
|
|
||||||
|
@ -1479,9 +1480,13 @@ struct ent_originate_ringback {
|
||||||
static void *SWITCH_THREAD_FUNC enterprise_originate_thread(switch_thread_t *thread, void *obj)
|
static void *SWITCH_THREAD_FUNC enterprise_originate_thread(switch_thread_t *thread, void *obj)
|
||||||
{
|
{
|
||||||
enterprise_originate_handle_t *handle = (enterprise_originate_handle_t *) obj;
|
enterprise_originate_handle_t *handle = (enterprise_originate_handle_t *) obj;
|
||||||
|
switch_status_t status;
|
||||||
|
|
||||||
|
switch_mutex_lock(handle->fence_mutex);
|
||||||
handle->done = 0;
|
handle->done = 0;
|
||||||
handle->status = switch_ivr_originate(NULL, &handle->bleg, &handle->cause,
|
switch_mutex_unlock(handle->fence_mutex);
|
||||||
|
|
||||||
|
status = switch_ivr_originate(NULL, &handle->bleg, &handle->cause,
|
||||||
handle->bridgeto, handle->timelimit_sec,
|
handle->bridgeto, handle->timelimit_sec,
|
||||||
handle->table,
|
handle->table,
|
||||||
handle->cid_name_override,
|
handle->cid_name_override,
|
||||||
|
@ -1492,8 +1497,11 @@ static void *SWITCH_THREAD_FUNC enterprise_originate_thread(switch_thread_t *thr
|
||||||
&handle->cancel_cause,
|
&handle->cancel_cause,
|
||||||
handle->dh);
|
handle->dh);
|
||||||
|
|
||||||
|
switch_mutex_lock(handle->fence_mutex);
|
||||||
|
handle->status = status;
|
||||||
handle->done = 1;
|
handle->done = 1;
|
||||||
|
switch_mutex_unlock(handle->fence_mutex);
|
||||||
|
|
||||||
switch_mutex_lock(handle->mutex);
|
switch_mutex_lock(handle->mutex);
|
||||||
switch_mutex_unlock(handle->mutex);
|
switch_mutex_unlock(handle->mutex);
|
||||||
|
|
||||||
|
@ -1697,6 +1705,7 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_enterprise_originate(switch_core_sess
|
||||||
switch_dial_handle_dup(&handles[i].dh, hl->handles[i]);
|
switch_dial_handle_dup(&handles[i].dh, hl->handles[i]);
|
||||||
}
|
}
|
||||||
switch_mutex_init(&handles[i].mutex, SWITCH_MUTEX_NESTED, pool);
|
switch_mutex_init(&handles[i].mutex, SWITCH_MUTEX_NESTED, pool);
|
||||||
|
switch_mutex_init(&handles[i].fence_mutex, SWITCH_MUTEX_NESTED, pool);
|
||||||
switch_mutex_lock(handles[i].mutex);
|
switch_mutex_lock(handles[i].mutex);
|
||||||
switch_thread_create(&handles[i].thread, thd_attr, enterprise_originate_thread, &handles[i], pool);
|
switch_thread_create(&handles[i].thread, thd_attr, enterprise_originate_thread, &handles[i], pool);
|
||||||
}
|
}
|
||||||
|
@ -1738,13 +1747,14 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_enterprise_originate(switch_core_sess
|
||||||
|
|
||||||
for (i = 0; i < x_argc; i++) {
|
for (i = 0; i < x_argc; i++) {
|
||||||
|
|
||||||
|
switch_mutex_lock(handles[i].fence_mutex);
|
||||||
if (handles[i].done == 0) {
|
if (handles[i].done == 0) {
|
||||||
running++;
|
running++;
|
||||||
} else if (handles[i].done == 1) {
|
} else if (handles[i].done == 1) {
|
||||||
if (handles[i].status == SWITCH_STATUS_SUCCESS) {
|
if (handles[i].status == SWITCH_STATUS_SUCCESS) {
|
||||||
handles[i].done = 2;
|
handles[i].done = 2;
|
||||||
hp = &handles[i];
|
hp = &handles[i];
|
||||||
|
switch_mutex_unlock(handles[i].fence_mutex);
|
||||||
goto done;
|
goto done;
|
||||||
} else {
|
} else {
|
||||||
handles[i].done = -1;
|
handles[i].done = -1;
|
||||||
|
@ -1753,6 +1763,8 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_enterprise_originate(switch_core_sess
|
||||||
over++;
|
over++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
switch_mutex_unlock(handles[i].fence_mutex);
|
||||||
|
|
||||||
switch_yield(10000);
|
switch_yield(10000);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -680,8 +680,8 @@ static int vxprintf(void (*func) (void *, const char *, int), /* Consumer of tex
|
||||||
case etSQLESCAPE2:
|
case etSQLESCAPE2:
|
||||||
case etSQLESCAPE4:
|
case etSQLESCAPE4:
|
||||||
case etSQLESCAPE3:{
|
case etSQLESCAPE3:{
|
||||||
int i, j, n, ch, isnull;
|
size_t i, j, n, ch;
|
||||||
int needQuote;
|
int needQuote, isnull;
|
||||||
char *escarg = va_arg(ap, char *);
|
char *escarg = va_arg(ap, char *);
|
||||||
isnull = escarg == 0;
|
isnull = escarg == 0;
|
||||||
if (isnull)
|
if (isnull)
|
||||||
|
|
|
@ -4764,11 +4764,12 @@ SWITCH_DECLARE(switch_status_t) switch_rtp_activate_ice(switch_rtp_t *rtp_sessio
|
||||||
if ((type & ICE_VANILLA)) {
|
if ((type & ICE_VANILLA)) {
|
||||||
switch_snprintf(ice_user, sizeof(ice_user), "%s:%s", login, rlogin);
|
switch_snprintf(ice_user, sizeof(ice_user), "%s:%s", login, rlogin);
|
||||||
switch_snprintf(user_ice, sizeof(user_ice), "%s:%s", rlogin, login);
|
switch_snprintf(user_ice, sizeof(user_ice), "%s:%s", rlogin, login);
|
||||||
switch_snprintf(luser_ice, sizeof(user_ice), "%s%s", rlogin, login);
|
switch_snprintf(luser_ice, sizeof(luser_ice), "%s%s", rlogin, login);
|
||||||
ice->ready = ice->rready = 0;
|
ice->ready = ice->rready = 0;
|
||||||
} else {
|
} else {
|
||||||
switch_snprintf(ice_user, sizeof(ice_user), "%s%s", login, rlogin);
|
switch_snprintf(ice_user, sizeof(ice_user), "%s%s", login, rlogin);
|
||||||
switch_snprintf(user_ice, sizeof(user_ice), "%s%s", rlogin, login);
|
switch_snprintf(user_ice, sizeof(user_ice), "%s%s", rlogin, login);
|
||||||
|
switch_snprintf(luser_ice, sizeof(luser_ice), "");
|
||||||
ice->ready = ice->rready = 1;
|
ice->ready = ice->rready = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1243,15 +1243,17 @@ SWITCH_MODULE_RUNTIME_FUNCTION(softtimer_runtime)
|
||||||
if (runtime.sps <= 0) {
|
if (runtime.sps <= 0) {
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Over Session Rate of %d!\n", runtime.sps_total);
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Over Session Rate of %d!\n", runtime.sps_total);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* These two mutexes must be held in exact order: session_hash_mutex and then throttle_mutex. See switch_core_session_request_uuid() */
|
||||||
|
switch_mutex_lock(runtime.session_hash_mutex);
|
||||||
switch_mutex_lock(runtime.throttle_mutex);
|
switch_mutex_lock(runtime.throttle_mutex);
|
||||||
runtime.sps_last = runtime.sps_total - runtime.sps;
|
runtime.sps_last = runtime.sps_total - runtime.sps;
|
||||||
|
|
||||||
if (sps_interval_ticks >= 300) {
|
if (sps_interval_ticks >= 300) {
|
||||||
runtime.sps_peak_fivemin = 0;
|
runtime.sps_peak_fivemin = 0;
|
||||||
sps_interval_ticks = 0;
|
sps_interval_ticks = 0;
|
||||||
switch_mutex_lock(runtime.session_hash_mutex);
|
/* This line is protected by runtime.session_hash_mutex */
|
||||||
runtime.sessions_peak_fivemin = session_manager.session_count;
|
runtime.sessions_peak_fivemin = session_manager.session_count;
|
||||||
switch_mutex_unlock(runtime.session_hash_mutex);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
sps_interval_ticks++;
|
sps_interval_ticks++;
|
||||||
|
@ -1265,6 +1267,7 @@ SWITCH_MODULE_RUNTIME_FUNCTION(softtimer_runtime)
|
||||||
}
|
}
|
||||||
runtime.sps = runtime.sps_total;
|
runtime.sps = runtime.sps_total;
|
||||||
switch_mutex_unlock(runtime.throttle_mutex);
|
switch_mutex_unlock(runtime.throttle_mutex);
|
||||||
|
switch_mutex_unlock(runtime.session_hash_mutex);
|
||||||
tick = 0;
|
tick = 0;
|
||||||
}
|
}
|
||||||
#ifndef DISABLE_1MS_COND
|
#ifndef DISABLE_1MS_COND
|
||||||
|
|
|
@ -36,6 +36,8 @@
|
||||||
#include <openssl/ssl.h>
|
#include <openssl/ssl.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define ENABLE_SNPRINTFV_TESTS 0 /* Do not turn on for CI as this requires a lot of RAM */
|
||||||
|
|
||||||
FST_CORE_BEGIN("./conf")
|
FST_CORE_BEGIN("./conf")
|
||||||
{
|
{
|
||||||
FST_SUITE_BEGIN(switch_core)
|
FST_SUITE_BEGIN(switch_core)
|
||||||
|
@ -51,6 +53,61 @@ FST_CORE_BEGIN("./conf")
|
||||||
}
|
}
|
||||||
FST_TEARDOWN_END()
|
FST_TEARDOWN_END()
|
||||||
|
|
||||||
|
#if ENABLE_SNPRINTFV_TESTS
|
||||||
|
FST_TEST_BEGIN(test_snprintfv_1)
|
||||||
|
{
|
||||||
|
size_t src_buf_size = 0x100000001;
|
||||||
|
char* src = calloc(1, src_buf_size);
|
||||||
|
|
||||||
|
if (!src) {
|
||||||
|
printf("bad allocation\n");
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
src[0] = '\xc0';
|
||||||
|
memset(src + 1, '\x80', 0xffffffff);
|
||||||
|
|
||||||
|
char dst[256];
|
||||||
|
switch_snprintfv(dst, 256, "'%!q'", src);
|
||||||
|
free(src);
|
||||||
|
}
|
||||||
|
FST_TEST_END()
|
||||||
|
|
||||||
|
FST_TEST_BEGIN(test_snprintfv_2)
|
||||||
|
{
|
||||||
|
#define STR_LEN ((0x100000001 - 3) / 2)
|
||||||
|
|
||||||
|
char* src = calloc(1, STR_LEN + 1); /* Account for NULL byte. */
|
||||||
|
|
||||||
|
if (!src) { return -1; }
|
||||||
|
|
||||||
|
memset(src, 'a', STR_LEN);
|
||||||
|
|
||||||
|
char* dst = calloc(1, STR_LEN + 3); /* Account for extra quotes and NULL byte */
|
||||||
|
if (!dst) { return -1; }
|
||||||
|
|
||||||
|
switch_snprintfv(dst, 2 * STR_LEN + 3, "'%q'", src);
|
||||||
|
|
||||||
|
free(src);
|
||||||
|
free(dst);
|
||||||
|
}
|
||||||
|
FST_TEST_END()
|
||||||
|
#endif
|
||||||
|
|
||||||
|
FST_TEST_BEGIN(test_md5)
|
||||||
|
{
|
||||||
|
char digest[SWITCH_MD5_DIGEST_STRING_SIZE] = { 0 };
|
||||||
|
char test_string[] = "test";
|
||||||
|
switch_status_t status;
|
||||||
|
|
||||||
|
status = switch_md5_string(digest, (void *)test_string, strlen(test_string));
|
||||||
|
|
||||||
|
fst_check_int_equals(status, SWITCH_STATUS_SUCCESS);
|
||||||
|
fst_check_string_equals(digest, "098f6bcd4621d373cade4e832627b4f6");
|
||||||
|
}
|
||||||
|
FST_TEST_END()
|
||||||
|
|
||||||
FST_TEST_BEGIN(test_switch_event_add_header_leak)
|
FST_TEST_BEGIN(test_switch_event_add_header_leak)
|
||||||
{
|
{
|
||||||
switch_event_t* event;
|
switch_event_t* event;
|
||||||
|
|
|
@ -128,7 +128,7 @@ if not exist "$(OutDir)fonts" xcopy "$(SolutionDir)fonts\*.*" "$(OutDir)fonts\"
|
||||||
<BuildLog />
|
<BuildLog />
|
||||||
<ClCompile>
|
<ClCompile>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite-amalgamation-3080401;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<MinimalRebuild>true</MinimalRebuild>
|
<MinimalRebuild>true</MinimalRebuild>
|
||||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||||
|
@ -178,7 +178,7 @@ if not exist "$(OutDir)fonts" xcopy "$(SolutionDir)fonts\*.*" "$(OutDir)fonts\"
|
||||||
</Midl>
|
</Midl>
|
||||||
<ClCompile>
|
<ClCompile>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite-amalgamation-3080401;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<MinimalRebuild>true</MinimalRebuild>
|
<MinimalRebuild>true</MinimalRebuild>
|
||||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||||
|
@ -219,7 +219,7 @@ if not exist "$(OutDir)fonts" xcopy "$(SolutionDir)fonts\*.*" "$(OutDir)fonts\"
|
||||||
<BuildLog />
|
<BuildLog />
|
||||||
<ClCompile>
|
<ClCompile>
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite-amalgamation-3080401;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;CRASH_PROT;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;CRASH_PROT;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||||
<PrecompiledHeader>Create</PrecompiledHeader>
|
<PrecompiledHeader>Create</PrecompiledHeader>
|
||||||
|
@ -257,7 +257,7 @@ if not exist "$(OutDir)fonts" xcopy "$(SolutionDir)fonts\*.*" "$(OutDir)fonts\"
|
||||||
</Midl>
|
</Midl>
|
||||||
<ClCompile>
|
<ClCompile>
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite-amalgamation-3080401;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\src\include;..\..\libs\include;..\..\libs\srtp\include;..\..\libs\srtp\crypto\include;..\..\libs\libteletone\src;..\..\libs\sqlite;..\..\libs\speex-1.2rc1\include;..\..\libs\spandsp\src\msvc;..\..\libs\spandsp\src;..\..\libs\libtpl-1.5\src;..\..\libs\libtpl-1.5\src\win;..\..\libs\sofia-sip\libsofia-sip-ua\sdp;..\..\libs\sofia-sip\libsofia-sip-ua\su;..\..\libs\sofia-sip\win32;..\..\libs\libyuv\include;..\..\libs\freetype\include;..\..\libs\libpng;..\..\libs\libvpx;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;CRASH_PROT;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>CJSON_EXPORT_SYMBOLS;_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_WINDOWS;_USRDLL;FREESWITCHCORE_EXPORTS;STATICLIB;CRASH_PROT;TPL_NOLIB;LIBSOFIA_SIP_UA_STATIC;SWITCH_HAVE_YUV;SWITCH_HAVE_VPX;SWITCH_HAVE_PNG;SWITCH_HAVE_FREETYPE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||||
<PrecompiledHeader>Create</PrecompiledHeader>
|
<PrecompiledHeader>Create</PrecompiledHeader>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ImportGroup Label="PropertySheets" />
|
<ImportGroup Label="PropertySheets" />
|
||||||
<PropertyGroup Label="UserMacros">
|
<PropertyGroup Label="UserMacros">
|
||||||
<curlVersion>7.78.0</curlVersion>
|
<curlVersion>7.88.0</curlVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<curlVersionImported>true</curlVersionImported>
|
<curlVersionImported>true</curlVersionImported>
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<downloadsqlitePropsImported>true</downloadsqlitePropsImported>
|
<downloadsqlitePropsImported>true</downloadsqlitePropsImported>
|
||||||
|
<sqliteVersion>3400000</sqliteVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
|
@ -29,11 +30,12 @@
|
||||||
|
|
||||||
<Target Name="sqliteDownloadTarget" BeforeTargets="CustomBuild;PreBuildEvent;" DependsOnTargets="7za">
|
<Target Name="sqliteDownloadTarget" BeforeTargets="CustomBuild;PreBuildEvent;" DependsOnTargets="7za">
|
||||||
<DownloadPackageTask
|
<DownloadPackageTask
|
||||||
package="http://files.freeswitch.org/downloads/libs/sqlite-amalgamation-3080401.zip"
|
package="http://files.freeswitch.org/downloads/libs/sqlite-amalgamation-$(sqliteVersion).zip"
|
||||||
expectfileordirectory="$(BaseDir)libs\sqlite-amalgamation-3080401\sqlite3.c"
|
expectfileordirectory="$(BaseDir)libs\sqlite\sqlite3.c"
|
||||||
outputfolder=""
|
outputfolder=""
|
||||||
outputfilename=""
|
outputfilename=""
|
||||||
extractto="$(BaseDir)libs\"
|
extractto="$(BaseDir)libs\"
|
||||||
|
moveafter="sqlite-amalgamation-$(sqliteVersion)|sqlite"
|
||||||
/>
|
/>
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
|
|
|
@ -100,7 +100,14 @@ using System.Diagnostics;
|
||||||
Uri uri = new Uri(package);
|
Uri uri = new Uri(package);
|
||||||
string urifilename = Path.GetFileName(uri.LocalPath);
|
string urifilename = Path.GetFileName(uri.LocalPath);
|
||||||
string output = Path.Combine(outputfolder ?? librarypath, (outputfilename ?? urifilename));
|
string output = Path.Combine(outputfolder ?? librarypath, (outputfilename ?? urifilename));
|
||||||
|
string cachedir = Environment.GetEnvironmentVariable("FreeSWITCHBuildCachePath") ?? "";
|
||||||
|
string cached_file = cachedir != "" ? Path.Combine(cachedir, (outputfilename ?? urifilename)) : "";
|
||||||
|
|
||||||
|
if (cached_file != "" && File.Exists(cached_file)) {
|
||||||
|
Log.LogMessage(MessageImportance.High,
|
||||||
|
"Found package in cache \"" + cached_file + "\".");
|
||||||
|
File.Copy(cached_file, output);
|
||||||
|
} else
|
||||||
//if (!File.Exists(output)) // Uncomment to skip download if exists
|
//if (!File.Exists(output)) // Uncomment to skip download if exists
|
||||||
{
|
{
|
||||||
var syncObject = new State
|
var syncObject = new State
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros">
|
<PropertyGroup Label="UserMacros">
|
||||||
<libksVersion>1.8.0</libksVersion>
|
<libksVersion>1.8.2</libksVersion>
|
||||||
|
<libksBuildNumber>1</libksBuildNumber>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<libksVersionImported>true</libksVersionImported>
|
<libksVersionImported>true</libksVersionImported>
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
|
|
||||||
<Target Name="libksBinariesDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
<Target Name="libksBinariesDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
||||||
<DownloadPackageTask
|
<DownloadPackageTask
|
||||||
package="http://files.freeswitch.org/windows/packages/libks/$(libksVersion)/libks-$(libksVersion)-binaries-$(Platform.ToLower())-$(Configuration.ToLower()).zip"
|
package="http://files.freeswitch.org/windows/packages/libks/$(libksVersion)_$(libksBuildNumber)/libks-$(libksVersion)_$(libksBuildNumber)-binaries-$(Platform.ToLower())-$(Configuration.ToLower()).zip"
|
||||||
expectfileordirectory="$(libksDir)\binaries\$(Platform)\$(Configuration)\ks.dll"
|
expectfileordirectory="$(libksDir)\binaries\$(Platform)\$(Configuration)\ks.dll"
|
||||||
outputfolder=""
|
outputfolder=""
|
||||||
outputfilename=""
|
outputfilename=""
|
||||||
|
@ -45,7 +45,7 @@
|
||||||
</Target>
|
</Target>
|
||||||
<Target Name="libksHeadersDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
<Target Name="libksHeadersDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
||||||
<DownloadPackageTask
|
<DownloadPackageTask
|
||||||
package="http://files.freeswitch.org/windows/packages/libks/$(libksVersion)/libks-$(libksVersion)-headers.zip"
|
package="http://files.freeswitch.org/windows/packages/libks/$(libksVersion)_$(libksBuildNumber)/libks-$(libksVersion)_$(libksBuildNumber)-headers.zip"
|
||||||
expectfileordirectory="$(libksDir)\src\include\libks\ks.h"
|
expectfileordirectory="$(libksDir)\src\include\libks\ks.h"
|
||||||
outputfolder=""
|
outputfolder=""
|
||||||
outputfilename=""
|
outputfilename=""
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros">
|
<PropertyGroup Label="UserMacros">
|
||||||
<libpqVersion>10.18</libpqVersion>
|
<libpqVersion>10.23</libpqVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<libpqVersionImported>true</libpqVersionImported>
|
<libpqVersionImported>true</libpqVersionImported>
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros">
|
<PropertyGroup Label="UserMacros">
|
||||||
<OpenSSLVersion>1.1.1l</OpenSSLVersion>
|
<OpenSSLVersion>1.1.1t</OpenSSLVersion>
|
||||||
<OpenSSLLibDir>$(BaseDir)libs\openssl-$(OpenSSLVersion)</OpenSSLLibDir>
|
<OpenSSLLibDir>$(BaseDir)libs\openssl-$(OpenSSLVersion)</OpenSSLLibDir>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
|
|
@ -68,7 +68,7 @@
|
||||||
<AdditionalIncludeDirectories>$(OpenSSLLibDir)\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>$(OpenSSLLibDir)\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<AdditionalIncludeDirectories Condition="'$(Platform)'=='Win32'">$(OpenSSLLibDir)\include_x86;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories Condition="'$(Platform)'=='Win32'">$(OpenSSLLibDir)\include_x86;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<AdditionalIncludeDirectories Condition="'$(Platform)'=='x64'">$(OpenSSLLibDir)\include_x64;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories Condition="'$(Platform)'=='x64'">$(OpenSSLLibDir)\include_x64;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>OPENSSL;HAVE_OPENSSL;HAVE_OPENSSL_DTLS_SRTP;HAVE_OPENSSL_DTLS;HAVE_OPENSSL_DTLSv1_2_method;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>HAVE_LIBCRYPTO;OPENSSL;HAVE_OPENSSL;HAVE_OPENSSL_DTLS_SRTP;HAVE_OPENSSL_DTLS;HAVE_OPENSSL_DTLSv1_2_method;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalLibraryDirectories>$(OpenSSLLibDir)\binaries\$(Platform)\$(LibraryConfiguration)\;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>$(OpenSSLLibDir)\binaries\$(Platform)\$(LibraryConfiguration)\;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros">
|
<PropertyGroup Label="UserMacros">
|
||||||
<rabbitmq_cVersion>0.11.0</rabbitmq_cVersion>
|
<rabbitmq_cVersion>0.13.0</rabbitmq_cVersion>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<rabbitmq_cVersionImported>true</rabbitmq_cVersionImported>
|
<rabbitmq_cVersionImported>true</rabbitmq_cVersionImported>
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
<Import Project="basedir.props" Condition=" '$(BaseDirImported)' == ''"/>
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros">
|
<PropertyGroup Label="UserMacros">
|
||||||
<signalwire-client-cVersion>1.3.0</signalwire-client-cVersion>
|
<signalwire-client-cVersion>1.3.2</signalwire-client-cVersion>
|
||||||
|
<signalwire-client-cBuildNumber>1</signalwire-client-cBuildNumber>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<signalwire-client-cVersionImported>true</signalwire-client-cVersionImported>
|
<signalwire-client-cVersionImported>true</signalwire-client-cVersionImported>
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
|
|
||||||
<Target Name="signalwire-client-cBinariesDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
<Target Name="signalwire-client-cBinariesDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
||||||
<DownloadPackageTask
|
<DownloadPackageTask
|
||||||
package="http://files.freeswitch.org/windows/packages/signalwire-client-c/$(signalwire-client-cVersion)/signalwire-client-c-$(signalwire-client-cVersion)-binaries-$(Platform.ToLower())-$(Configuration.ToLower()).zip"
|
package="http://files.freeswitch.org/windows/packages/signalwire-client-c/$(signalwire-client-cVersion)_$(signalwire-client-cBuildNumber)/signalwire-client-c-$(signalwire-client-cVersion)_$(signalwire-client-cBuildNumber)-binaries-$(Platform.ToLower())-$(Configuration.ToLower()).zip"
|
||||||
expectfileordirectory="$(signalwire-client-cDir)\binaries\$(Platform)\$(Configuration)\signalwire_client.dll"
|
expectfileordirectory="$(signalwire-client-cDir)\binaries\$(Platform)\$(Configuration)\signalwire_client.dll"
|
||||||
outputfolder=""
|
outputfolder=""
|
||||||
outputfilename=""
|
outputfilename=""
|
||||||
|
@ -43,7 +43,7 @@
|
||||||
</Target>
|
</Target>
|
||||||
<Target Name="signalwire-client-cHeadersDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
<Target Name="signalwire-client-cHeadersDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="7za">
|
||||||
<DownloadPackageTask
|
<DownloadPackageTask
|
||||||
package="http://files.freeswitch.org/windows/packages/signalwire-client-c/$(signalwire-client-cVersion)/signalwire-client-c-$(signalwire-client-cVersion)-headers.zip"
|
package="http://files.freeswitch.org/windows/packages/signalwire-client-c/$(signalwire-client-cVersion)_$(signalwire-client-cBuildNumber)/signalwire-client-c-$(signalwire-client-cVersion)_$(signalwire-client-cBuildNumber)-headers.zip"
|
||||||
expectfileordirectory="$(signalwire-client-cDir)\include\signalwire-client-c\client.h"
|
expectfileordirectory="$(signalwire-client-cDir)\include\signalwire-client-c\client.h"
|
||||||
outputfolder=""
|
outputfolder=""
|
||||||
outputfilename=""
|
outputfilename=""
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<YasmPropsImported>true</YasmPropsImported>
|
<YasmPropsImported>true</YasmPropsImported>
|
||||||
|
<Is64yasm Condition="$([System.Environment]::Is64BitProcess)">true</Is64yasm>
|
||||||
|
<PackageToDownload Condition="'$(Is64yasm)' == 'true'">http://files.freeswitch.org/downloads/win64/yasm.exe</PackageToDownload>
|
||||||
|
<PackageToDownload Condition="'$(Is64yasm)' != 'true'">http://files.freeswitch.org/downloads/win32/yasm.exe</PackageToDownload>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
|
@ -28,8 +31,9 @@
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<Target Name="YasmDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="">
|
<Target Name="YasmDownloadTarget" BeforeTargets="CustomBuild" DependsOnTargets="">
|
||||||
|
<Message Text="System is 64 bit." Condition="'$(Is64yasm)' == 'true'" Importance="High" />
|
||||||
<DownloadPackageTask
|
<DownloadPackageTask
|
||||||
package="http://files.freeswitch.org/downloads/win32/yasm.exe"
|
package="$(PackageToDownload)"
|
||||||
expectfileordirectory="$(ProjectDir)\yasm.exe"
|
expectfileordirectory="$(ProjectDir)\yasm.exe"
|
||||||
outputfolder="$(ProjectDir)\"
|
outputfolder="$(ProjectDir)\"
|
||||||
outputfilename=""
|
outputfilename=""
|
||||||
|
|
Loading…
Reference in New Issue