From d37e618afa2b3b5364c1e537149f5c6404afc6c1 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Wed, 2 Jun 2010 15:09:18 +0200 Subject: [PATCH] fix crash --- coreapi/callbacks.c | 1 + coreapi/linphonecore.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/coreapi/callbacks.c b/coreapi/callbacks.c index 8cb094121..eb2589c71 100644 --- a/coreapi/callbacks.c +++ b/coreapi/callbacks.c @@ -218,6 +218,7 @@ static void call_accepted(SalOp *op){ }//if there is an accepted incoming call else { + linphone_core_set_as_current_call (lc,call); gstate_new_state(lc, GSTATE_CALL_OUT_CONNECTED, NULL); linphone_connect_incoming(lc,call); } diff --git a/coreapi/linphonecore.c b/coreapi/linphonecore.c index a58061421..277cbf13d 100644 --- a/coreapi/linphonecore.c +++ b/coreapi/linphonecore.c @@ -313,7 +313,7 @@ int linphone_core_get_current_call_duration(const LinphoneCore *lc){ const LinphoneAddress *linphone_core_get_current_call_remote_address(struct _LinphoneCore *lc){ LinphoneCall *call=linphone_core_get_current_call(lc); - if (call==NULL) return 0; + if (call==NULL) return NULL; return linphone_call_get_remote_address(call); }