Commit b8e643f7 authored by Guillaume BIENKOWSKI's avatar Guillaume BIENKOWSKI

Fix reinvite in case of redirection: we should use the...

Fix reinvite in case of redirection: we should use the linphone_core_restart_invite function, which correctly handles the streams close/reopen
parent b58f23ec
......@@ -772,8 +772,11 @@ static void call_failure(SalOp *op){
char* url = linphone_address_as_string(redirection_to);
ms_warning("Redirecting call [%p] to %s",call, url);
ms_free(url);
linphone_call_create_op(call);
linphone_core_start_invite(lc, call, redirection_to);
if( call->log->to != NULL ) {
linphone_address_unref(call->log->to);
}
call->log->to = linphone_address_ref(redirection_to);
linphone_core_restart_invite(lc, call);
return;
}
}
......
......@@ -1820,6 +1820,7 @@ static void call_waiting_indication_with_param(bool_t enable_caller_privacy) {
/*use playfile for callee to avoid locking on capture card*/
linphone_core_use_files (laure->lc,TRUE);
linphone_core_use_files (marie->lc,TRUE);
snprintf(hellopath,sizeof(hellopath), "%s/sounds/hello8000.wav", liblinphone_tester_file_prefix);
linphone_core_set_play_file(laure->lc,hellopath);
if (enable_caller_privacy)
......@@ -1844,7 +1845,8 @@ static void call_waiting_indication_with_param(bool_t enable_caller_privacy) {
LinphoneCall *call=(LinphoneCall *)iterator->data;
if (call != pauline_called_by_marie) {
/*fine, this is the call waiting*/
linphone_core_accept_call(pauline->lc,pauline_called_by_laure=call);
pauline_called_by_laure=call;
linphone_core_accept_call(pauline->lc,pauline_called_by_laure);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment