From c88983da3d4a48aaadb1ea2d23f6062897fe31ac Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Fri, 20 Oct 2017 10:43:06 +0200 Subject: [PATCH] Fixed compil for android armv7, issue was cast increases required alignment from 4 to 8 --- coreapi/linphonecore.c | 2 +- coreapi/misc.c | 2 +- src/c-wrapper/api/c-call-stats.cpp | 2 +- tester/call_single_tester.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/coreapi/linphonecore.c b/coreapi/linphonecore.c index 8e8ab2df0..47be80186 100644 --- a/coreapi/linphonecore.c +++ b/coreapi/linphonecore.c @@ -2317,7 +2317,7 @@ LinphoneCore *linphone_core_new(const LinphoneCoreVTable *vtable, } LinphoneCore *linphone_core_ref(LinphoneCore *lc) { - return (LinphoneCore *)belle_sip_object_ref(BELLE_SIP_OBJECT(lc)); + return reinterpret_cast(belle_sip_object_ref(BELLE_SIP_OBJECT(lc))); } void linphone_core_unref(LinphoneCore *lc) { diff --git a/coreapi/misc.c b/coreapi/misc.c index c48265397..41f14fd92 100644 --- a/coreapi/misc.c +++ b/coreapi/misc.c @@ -167,7 +167,7 @@ int parse_hostname_to_addr(const char *server, struct sockaddr_storage *ss, sock return -1; } if (!res) return -1; - memcpy(ss,res->ai_addr,res->ai_addrlen); + memcpy(ss,res->ai_addr,(size_t)res->ai_addrlen); *socklen=(socklen_t)res->ai_addrlen; freeaddrinfo(res); return 0; diff --git a/src/c-wrapper/api/c-call-stats.cpp b/src/c-wrapper/api/c-call-stats.cpp index 50caec3f8..76dfd56f0 100644 --- a/src/c-wrapper/api/c-call-stats.cpp +++ b/src/c-wrapper/api/c-call-stats.cpp @@ -160,7 +160,7 @@ bool_t _linphone_call_stats_rtcp_received_via_mux (const LinphoneCallStats *stat // ============================================================================= LinphoneCallStats *linphone_call_stats_ref (LinphoneCallStats* stats) { - return (LinphoneCallStats*) belle_sip_object_ref(stats); + return reinterpret_cast(belle_sip_object_ref(stats)); } void linphone_call_stats_unref (LinphoneCallStats* stats) { diff --git a/tester/call_single_tester.c b/tester/call_single_tester.c index 9d3d108c6..7e2d0126a 100644 --- a/tester/call_single_tester.c +++ b/tester/call_single_tester.c @@ -864,7 +864,7 @@ static void call_with_specified_codec_bitrate(void) { int max_bw=50; #ifdef __arm__ - if (ms_factory_get_cpu_count(marie->lc->factory) <2) { /*2 opus codec channel + resampler is too much for a single core*/ + if (ms_factory_get_cpu_count(linphone_core_get_ms_factory(marie->lc)) <2) { /*2 opus codec channel + resampler is too much for a single core*/ #ifndef __ANDROID__ codec = "speex"; rate = 8000;