|
From: | Vadim Lebedev |
Subject: | Re: [Linphone-developers] Small Bug fixes for oRTP |
Date: | Mon, 23 Nov 2009 16:20:03 +0100 |
User-agent: | Thunderbird 2.0.0.23 (X11/20090817) |
Ok, I've attached the diff file, Basicall in original rtp_session_update_payload_typethe line: session->hw_recv_pt=paytype; was before the "if (pt ....)" so it was modified even when payload was unknown and in payload_type_changed_notify did not check at all for payload code validity. This was causing problems when working against Xlite when doing Video calls. Upon call establishement Xlite does not send real video payload but sum kind of dummy rtp packet with invalid payoad code. Later when user push "Send Video" button Xlite start sending real payload... Before my modifiction the video stream in linphone was configured upon call establishement then suspended upon detection of incoming invalid payload code then re-configured upon detection of valid payload.... Thanks Vadim Simon Morlat wrote: Hi Vadim, Sorry I can't see what you changed in these functions. Maybe a diff would be more appropriate ? Simon Le vendredi 20 novembre 2009 à 19:49 +0100, Vadim Lebedev a écrit :The RTP specs explains that conforming implementation should ignore incoming packets with unrecognized payloads: So 'ive fixed two function is rtpsession.c to behave correctly: void rtp_session_update_payload_type(RtpSession *session, int paytype){ /* check if we support this payload type */ PayloadType *pt=rtp_profile_get_payload(session->rcv.profile,paytype); if (pt!=0){ session->hw_recv_pt=paytype; ortp_message ("payload type changed to %i(%s) !", paytype,pt->mime_type); payload_type_changed(session,pt); }else{ ortp_warning("Receiving packet with unknown payload type %i.",paytype); } } static void payload_type_changed_notify(RtpSession *session, int paytype){ PayloadType *pt = rtp_profile_get_payload(session->rcv.profile,paytype); if (pt) { session->rcv.pt = paytype; rtp_signal_table_emit (&session->on_payload_type_changed); } } Thanks Vadim _______________________________________________ Linphone-developers mailing list address@hidden http://lists.nongnu.org/mailman/listinfo/linphone-developers |
587d586 < session->hw_recv_pt=paytype; 588a588 > session->hw_recv_pt=paytype; 913,914c913,918 < session->rcv.pt = paytype; < rtp_signal_table_emit (&session->on_payload_type_changed); --- > PayloadType *pt = > rtp_profile_get_payload(session->rcv.profile,paytype); > > if (pt) { > session->rcv.pt = paytype; > rtp_signal_table_emit (&session->on_payload_type_changed); > }
[Prev in Thread] | Current Thread | [Next in Thread] |