forked from FFmpeg/FFmpeg
avformat/mpegts: fix iteration count in add_pid_to_pmt()
Fixes accessing uninitialized memory Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
09024fe681
commit
786594184a
1 changed files with 1 additions and 1 deletions
|
@ -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;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue