diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-11-04 19:31:59 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-11-04 19:31:59 +0100 |
commit | 786594184a1797cc4b573001f3eeb188d5912062 (patch) | |
tree | 37fcf691ff35c702a148f2c2a3918461838d06e8 /libavformat/mpegts.c | |
parent | 09024fe681e1969cedff9cb8fcf949ac992b7c06 (diff) | |
download | ffmpeg-786594184a1797cc4b573001f3eeb188d5912062.tar.gz |
avformat/mpegts: fix iteration count in add_pid_to_pmt()
Fixes accessing uninitialized memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/mpegts.c')
-rw-r--r-- | libavformat/mpegts.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c index 97e07a7f72..78aa13e8a1 100644 --- a/libavformat/mpegts.c +++ b/libavformat/mpegts.c @@ -306,7 +306,7 @@ static void add_pid_to_pmt(MpegTSContext *ts, unsigned int programid, if (p->nb_pids >= MAX_PIDS_PER_PROGRAM) return; - for (i = 0; i < MAX_PIDS_PER_PROGRAM; i++) + for (i = 0; i < p->nb_pids; i++) if (p->pids[i] == pid) return; |