init mediastream after call is accepted in case of iPhone build. If mediastream is init to early, linphone issues a SIGPIPE in case of incoming call while in background.

fixed error are:
	Error receiving RTP packet: Socket is not connected.
	Error receiving RTCP packet: Socket is not connected.
	linphone process event get a message 15
	CALL_ACK
	Error receiving RTP packet: Socket is not connected.
	Error receiving RTCP packet: Socket is not connected.
	Audio MSTicker: We are late of 51 miliseconds.
	synchronizing timestamp, diff=1520
	Error sending rtp packet: Broken pipe ; socket=16
	Error sending rtp packet: Broken pipe ; socket=16
	Error sending rtp packet: Broken pipe ; socket=16
	Error receiving RTP packet: Socket is not connected.
	Error receiving RTCP packet: Socket is not connected.
This commit is contained in:
Jehan Monnier 2010-07-21 14:25:17 +02:00
parent 3e8f9536ee
commit 1dc662bf49
2 changed files with 5 additions and 1 deletions

View file

@ -105,7 +105,9 @@ static void call_received(SalOp *h){
}
linphone_call_set_state(call,LCStateRinging);
sal_call_notify_ringing(h);
#if !(__IPHONE_OS_VERSION_MIN_REQUIRED >= 40000)
linphone_core_init_media_streams(lc,lc->call);
#endif
if (lc->vtable.inv_recv) lc->vtable.inv_recv(lc,tmp);
ms_free(barmesg);
ms_free(tmp);

View file

@ -2515,7 +2515,9 @@ int linphone_core_accept_call(LinphoneCore *lc, const char *url)
contact=get_fixed_contact(lc,call,cfg);
if (contact)
sal_op_set_contact(call->op,contact);
#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 40000
linphone_core_init_media_streams(lc,call);
#endif
sal_call_accept(call->op);
lc->vtable.display_status(lc,_("Connected."));
gstate_new_state(lc, GSTATE_CALL_IN_CONNECTED, NULL);