[FFmpeg-cvslog] r11050 - trunk/libavformat/mpegts.c
heydowns
subversion
Sat Nov 17 04:14:43 CET 2007
Author: heydowns
Date: Sat Nov 17 04:14:43 2007
New Revision: 11050
Log:
When new streams are detected, look for old filters and close them out.
This avoids crashes seen when legitimate streams are found on PID 0x11 instead
of DVB SDT.
Fixes regression detailed in Roundup issue 138.
Modified:
trunk/libavformat/mpegts.c
Modified: trunk/libavformat/mpegts.c
==============================================================================
--- trunk/libavformat/mpegts.c (original)
+++ trunk/libavformat/mpegts.c Sat Nov 17 04:14:43 2007
@@ -588,11 +588,11 @@ static void pmt_cb(MpegTSFilter *filter,
case STREAM_TYPE_AUDIO_AC3:
case STREAM_TYPE_AUDIO_DTS:
case STREAM_TYPE_SUBTITLE_DVB:
- if(ts->pids[pid]){
- assert(ts->pids[pid]->type == MPEGTS_PES);
+ if(ts->pids[pid] && ts->pids[pid]->type == MPEGTS_PES){
pes= ts->pids[pid]->u.pes_filter.opaque;
st= pes->st;
}else{
+ if (ts->pids[pid]) mpegts_close_filter(ts, ts->pids[pid]); //wrongly added sdt filter probably
pes = add_pes_stream(ts, pid, pcr_pid, stream_type);
if (pes)
st = new_pes_av_stream(pes, 0);
More information about the ffmpeg-cvslog
mailing list