From: RĂ©mi Denis-Courmont Date: Sun, 29 Jun 2008 17:41:33 +0000 (+0300) Subject: RTP: avoid loosing the first received packet X-Git-Tag: 0.9.0-test1~42 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=425a85df64f1c1671ea9536f0140a611a1e0d7a5;p=vlc RTP: avoid loosing the first received packet --- diff --git a/modules/demux/rtpsession.c b/modules/demux/rtpsession.c index 62c24fdcce..ccad2841a4 100644 --- a/modules/demux/rtpsession.c +++ b/modules/demux/rtpsession.c @@ -268,6 +268,13 @@ rtp_receive (demux_t *demux, rtp_session_t *session, block_t *block) tab[session->srcc++] = src; } + /* Be optimistic for the first packet. Certain codec, such as Vorbis + * do not like loosing the first packet(s), so we cannot just wait + * for proper sequence synchronization. And we don't want to assume that + * the sender starts at seq=0 either. */ + if (src->blocks == NULL) + src->max_seq = seq - p_sys->max_dropout; + /* Check sequence number */ /* NOTE: the sequence number is per-source, * but is independent from the payload type. */