mirror of https://git.ffmpeg.org/ffmpeg.git
matroskadec: avoid potential crash after r23169
Originally committed as revision 23330 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
344f5c9fb3
commit
37dd235658
|
@ -1793,7 +1793,7 @@ static int matroska_parse_cluster(MatroskaDemuxContext *matroska)
|
||||||
blocks_list = &cluster.blocks;
|
blocks_list = &cluster.blocks;
|
||||||
blocks = blocks_list->elem;
|
blocks = blocks_list->elem;
|
||||||
for (i=0; i<blocks_list->nb_elem; i++)
|
for (i=0; i<blocks_list->nb_elem; i++)
|
||||||
if (blocks[i].bin.size > 0) {
|
if (blocks[i].bin.size > 0 && blocks[i].bin.data) {
|
||||||
int is_keyframe = blocks[i].non_simple ? !blocks[i].reference : -1;
|
int is_keyframe = blocks[i].non_simple ? !blocks[i].reference : -1;
|
||||||
res=matroska_parse_block(matroska,
|
res=matroska_parse_block(matroska,
|
||||||
blocks[i].bin.data, blocks[i].bin.size,
|
blocks[i].bin.data, blocks[i].bin.size,
|
||||||
|
|
Loading…
Reference in New Issue