From 23967d8ca8c991898acb813afc775f2f49184fda Mon Sep 17 00:00:00 2001 From: Jehan Monnier Date: Tue, 21 May 2013 11:16:45 +0200 Subject: [PATCH] fix ortp initiale ref count. Remove abusive traces --- coreapi/bellesip_sal/sal_impl.c | 3 ++- coreapi/bellesip_sal/sal_op_call.c | 6 +++++- coreapi/linphonecall.c | 3 +-- coreapi/linphonecore.c | 3 ++- oRTP | 2 +- 5 files changed, 11 insertions(+), 6 deletions(-) diff --git a/coreapi/bellesip_sal/sal_impl.c b/coreapi/bellesip_sal/sal_impl.c index b07a7bdf9..1609703a4 100644 --- a/coreapi/bellesip_sal/sal_impl.c +++ b/coreapi/bellesip_sal/sal_impl.c @@ -127,7 +127,8 @@ static void process_io_error(void *user_ctx, const belle_sip_io_error_event_t *e op->callbacks.process_io_error(op,event); } } else { - ms_error("sal process_io_error not implemented yet for non transaction"); + /*ms_error("sal process_io_error not implemented yet for non transaction");*/ + /*nop, because already handle at transaction layer*/ } } diff --git a/coreapi/bellesip_sal/sal_op_call.c b/coreapi/bellesip_sal/sal_op_call.c index 28a46bd93..76ea05782 100644 --- a/coreapi/bellesip_sal/sal_op_call.c +++ b/coreapi/bellesip_sal/sal_op_call.c @@ -247,7 +247,11 @@ static void call_response_event(void *op_base, const belle_sip_response_event_t } else { /*nop error*/ } - ms_error("call op [%p] receive an unexpected answer [%i]",op,code); + if (code >= 100 && code < 180) { + ms_message("call op [%p] receive [%i]",op,code); + } else { + ms_error("call op [%p] receive an unexpected answer [%i]",op,code); + } } case BELLE_SIP_DIALOG_CONFIRMED: { switch (op->state) { diff --git a/coreapi/linphonecall.c b/coreapi/linphonecall.c index 3f2783b06..88f3869ed 100644 --- a/coreapi/linphonecall.c +++ b/coreapi/linphonecall.c @@ -223,8 +223,7 @@ void linphone_call_make_local_media_description(LinphoneCore *lc, LinphoneCall * SalMediaDescription *md=sal_media_description_new(); LinphoneAddress *addr; bool_t keep_srtp_keys=lp_config_get_int(lc->config,"sip","keep_srtp_keys",0); - char local_ip[256]; - linphone_core_get_local_ip_for( AF_INET,"linphone.org",local_ip); + char* local_ip=call->localip; linphone_core_adapt_to_network(lc,call->ping_time,&call->params); diff --git a/coreapi/linphonecore.c b/coreapi/linphonecore.c index 7e16f4403..449fb43e4 100644 --- a/coreapi/linphonecore.c +++ b/coreapi/linphonecore.c @@ -2799,7 +2799,8 @@ void linphone_core_notify_incoming_call(LinphoneCore *lc, LinphoneCall *call){ if (md){ if (sal_media_description_empty(md) || linphone_core_incompatible_security(lc,md)){ sal_call_decline(call->op,SalReasonMedia,NULL); - linphone_call_unref(call); + linphone_core_del_call(lc,call); + linphone_call_ref(call); return; } } diff --git a/oRTP b/oRTP index 2d8a82247..1a103971b 160000 --- a/oRTP +++ b/oRTP @@ -1 +1 @@ -Subproject commit 2d8a82247fbebbd690ae2fc8300522ab9b71a542 +Subproject commit 1a103971b84d39510ad14f327bd6834b3d88063f