[FFmpeg-cvslog] sdp: Ignore RTCP packets when autodetecting RTP streams
Martin Storsjö
git at videolan.org
Fri Feb 17 00:45:03 CET 2012
ffmpeg | branch: master | Martin Storsjö <martin at martin.st> | Mon Feb 13 17:05:43 2012 +0200| [f3a094f2da26f62f3461e78a22b115ab8a700b8d] | committer: Martin Storsjö
sdp: Ignore RTCP packets when autodetecting RTP streams
The rtp demuxer which listens for RTP packets and detects the
RTP payload type will currently get confused if the first packet
received is an RTCP packet. Thus ignore such packets.
Signed-off-by: Martin Storsjö <martin at martin.st>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f3a094f2da26f62f3461e78a22b115ab8a700b8d
---
libavformat/rtsp.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 1fb7b2b..f8611de 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -1927,6 +1927,9 @@ static int rtp_read_header(AVFormatContext *s)
continue;
}
+ if (recvbuf[1] >= RTCP_SR && recvbuf[1] <= RTCP_APP)
+ continue;
+
payload_type = recvbuf[1] & 0x7f;
break;
}
More information about the ffmpeg-cvslog
mailing list