mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-10-28 22:24:16 +00:00
windows build fixes.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5767 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
1 parent
87f62d1d0d
commit
8f963f4aea
7 files changed
+30
-38
No files matched your search
@@ -123,6 +123,7 @@
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(InputDir)..\..\..\include";"$(InputDir)include";"$(InputDir)..\..\..\..\libs\include";"$(InputDir)..\..\..\..\libs\udns""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;MOD_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
|
||||
@@ -916,7 +916,7 @@ static switch_status_t openmrcp_destroy()
|
||||
openmrcp_module.tts_profile = NULL;
|
||||
}
|
||||
|
||||
switch_core_hash_destroy(openmrcp_module.profile_hash);
|
||||
switch_core_hash_destroy(&openmrcp_module.profile_hash);
|
||||
openmrcp_module.profile_hash = NULL;
|
||||
|
||||
/* one-time mrcp global destroy */
|
||||
|
||||
@@ -326,49 +326,43 @@ void BaseCDR::process_channel_variables(const std::list<std::string>& stringlist
|
||||
// This one is for processing of supplemental chanvars
|
||||
void BaseCDR::process_channel_variables(const std::list<std::string>& stringlist, const std::list<std::string>& fixedlist, switch_channel_t *channel,bool repeat)
|
||||
{
|
||||
if(stringlist.front() == "*")
|
||||
{
|
||||
switch_hash_index_t *hi;
|
||||
void *val;
|
||||
const void *var;
|
||||
if(stringlist.front() == "*") {
|
||||
switch_event_header_t *hi;
|
||||
switch_memory_pool_t *sessionpool;
|
||||
sessionpool = switch_core_session_get_pool(coresession);
|
||||
for (hi = switch_channel_variable_first(channel); hi; hi = switch_hash_next(hi))
|
||||
{
|
||||
switch_hash_this(hi, &var, 0, &val);
|
||||
std::string tempstring_first, tempstring_second;
|
||||
tempstring_first = (char *) var;
|
||||
tempstring_second = (char *) val;
|
||||
chanvars_supp[tempstring_first] = tempstring_second;
|
||||
|
||||
if ((hi = switch_channel_variable_first(channel))) {
|
||||
for (; hi; hi = hi->next) {
|
||||
std::string name, value;
|
||||
name = hi->name;
|
||||
value = hi->value;
|
||||
|
||||
chanvars_supp[name] = value;
|
||||
}
|
||||
switch_channel_variable_last(channel);
|
||||
}
|
||||
switch_channel_variable_last(channel);
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
std::list<std::string>::const_iterator iItr,iEnd;
|
||||
iEnd = stringlist.end();
|
||||
|
||||
for(iItr = stringlist.begin(); iItr != iEnd; iItr++)
|
||||
{
|
||||
for (iItr = stringlist.begin(); iItr != iEnd; iItr++) {
|
||||
std::vector<char> tempstringvector(iItr->begin(), iItr->end());
|
||||
tempstringvector.push_back('\0');
|
||||
char* tempstring= &tempstringvector[0];
|
||||
|
||||
char *tempvariable;
|
||||
tempvariable = switch_channel_get_variable(channel,tempstring);
|
||||
if(!switch_strlen_zero(tempvariable))
|
||||
if (!switch_strlen_zero(tempvariable))
|
||||
chanvars_supp[*iItr] = tempvariable;
|
||||
}
|
||||
}
|
||||
|
||||
if(!repeat)
|
||||
{
|
||||
if (!repeat) {
|
||||
std::map<std::string,std::string>::iterator MapItr;
|
||||
std::list<std::string>::const_iterator iItr,iEnd;
|
||||
for(iItr = fixedlist.begin(), iEnd = fixedlist.end(); iItr != iEnd; iItr++)
|
||||
{
|
||||
for (iItr = fixedlist.begin(), iEnd = fixedlist.end(); iItr != iEnd; iItr++) {
|
||||
MapItr = chanvars_supp.find(*iItr);
|
||||
if(MapItr != chanvars_supp.end() )
|
||||
if (MapItr != chanvars_supp.end() )
|
||||
chanvars_supp.erase(MapItr);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ SWITCH_DECLARE_GLOBAL_STRING_FUNC(set_global_address, globals.address)
|
||||
char *next, *cur;
|
||||
uint32_t count = 0;
|
||||
uint8_t custom = 0;
|
||||
switch_ssize_t hlen = SWITCH_HASH_KEY_STRING;
|
||||
switch_ssize_t hlen = -1;
|
||||
|
||||
gethostname(globals.hostname, sizeof(globals.hostname));
|
||||
globals.host_hash = switch_hashfunc_default(globals.hostname, &hlen);
|
||||
@@ -107,7 +107,7 @@ SWITCH_DECLARE_GLOBAL_STRING_FUNC(set_global_address, globals.address)
|
||||
}
|
||||
|
||||
if (custom) {
|
||||
switch_core_hash_insert_dup(globals.event_hash, cur, MARKER);
|
||||
switch_core_hash_insert(globals.event_hash, cur, MARKER);
|
||||
} else if (switch_name_event(cur, &type) == SWITCH_STATUS_SUCCESS) {
|
||||
globals.key_count++;
|
||||
if (type == SWITCH_EVENT_ALL) {
|
||||
|
||||
Reference in new issue
Block a user