History

rtsp: Check if the rtp stream actually has an RTPDemuxContext

For example MS-RTSP doesn't have RTPDemuxContexts for all streams. This fixes issue 2448. Originally committed as revision 26107 to svn://svn.ffmpeg.org/ffmpeg/trunk

Martin Storsjö committed 15 years ago

Commit 9e99f841 parent 106f2711 file · +4 −1Browse files

Unified · Split

libavformat/rtsp.c+4−1
@@ -1557,7 +1557,10 @@ int ff_rtsp_fetch_packet(AVFormatContext *s, AVPacket *pkt) · 1556 unmodified lines
1557 int64_t first_queue_time = 0;1557 int64_t first_queue_time = 0;
1558 for (i = 0; i < rt->nb_rtsp_streams; i++) {1558 for (i = 0; i < rt->nb_rtsp_streams; i++) {
1559 RTPDemuxContext *rtpctx = rt->rtsp_streams[i]->transport_priv;1559 RTPDemuxContext *rtpctx = rt->rtsp_streams[i]->transport_priv;
1560 int64_t queue_time = ff_rtp_queued_packet_time(rtpctx);1560 int64_t queue_time;
1561 if (!rtpctx)
1562 continue;
1563 queue_time = ff_rtp_queued_packet_time(rtpctx);
1561 if (queue_time && (queue_time - first_queue_time < 0 ||1564 if (queue_time && (queue_time - first_queue_time < 0 ||
1562 !first_queue_time)) {1565 !first_queue_time)) {
1563 first_queue_time = queue_time;1566 first_queue_time = queue_time;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t