Tweaks to silence some compiler warnings on Windows

This commit is contained in:
Peter Olsson 2014-02-01 12:04:26 +01:00
parent 6d5bd4abaa
commit 609209d031
3 changed files with 8 additions and 4 deletions

View File

@ -2950,7 +2950,7 @@ SWITCH_STANDARD_API(uuid_set_media_stats)
return SWITCH_STATUS_SUCCESS;
}
#define add_stat(_i, _s) cJSON_AddItemToObject(jstats, _s, cJSON_CreateNumber(_i))
#define add_stat(_i, _s) cJSON_AddItemToObject(jstats, _s, cJSON_CreateNumber(((double)_i)))
static void jsonify_stats(cJSON *json, const char *name, switch_rtp_stats_t *stats)
{

View File

@ -1756,7 +1756,7 @@ static void *SWITCH_THREAD_FUNC o_thread_run(switch_thread_t *thread, void *obj)
sql = switch_mprintf("update fifo_outbound set ring_count=ring_count-1, "
"outbound_fail_count=outbound_fail_count+1, next_avail=%ld + lag + 1 where uuid='%q'",
(long) switch_epoch_time_now(NULL) + node->retry_delay, h->uuid);
(long) switch_epoch_time_now(NULL) + (node ? node->retry_delay : 0), h->uuid);
fifo_execute_sql_queued(&sql, SWITCH_TRUE, SWITCH_TRUE);
if (switch_event_create_subclass(&event, SWITCH_EVENT_CUSTOM, FIFO_EVENT) == SWITCH_STATUS_SUCCESS) {

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
@ -73,6 +73,7 @@
<AdditionalIncludeDirectories>..\..\..\..\libs\opus-1.1\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeader>
</PrecompiledHeader>
<DisableSpecificWarnings>6053;6340;6246;6011;6387;%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
<Link>
<RandomizedBaseAddress>false</RandomizedBaseAddress>
@ -88,6 +89,7 @@
<AdditionalIncludeDirectories>..\..\..\..\libs\opus-1.1\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeader>
</PrecompiledHeader>
<DisableSpecificWarnings>6053;6340;6246;6011;6387;%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
<Link>
<RandomizedBaseAddress>false</RandomizedBaseAddress>
@ -101,6 +103,7 @@
<AdditionalIncludeDirectories>..\..\..\..\libs\opus-1.1\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeader>
</PrecompiledHeader>
<DisableSpecificWarnings>6053;6340;6246;6011;6387;%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
<Link>
<RandomizedBaseAddress>false</RandomizedBaseAddress>
@ -116,6 +119,7 @@
<AdditionalIncludeDirectories>..\..\..\..\libs\opus-1.1\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeader>
</PrecompiledHeader>
<DisableSpecificWarnings>6053;6340;6246;6011;6387;%(DisableSpecificWarnings)</DisableSpecificWarnings>
</ClCompile>
<Link>
<RandomizedBaseAddress>false</RandomizedBaseAddress>
@ -153,4 +157,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>