diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2019-05-17 00:29:53 +0200 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2019-06-23 00:47:50 -0300 |
commit | f3ca3e7f19c86563c2d3bca82962567396b1cc13 (patch) | |
tree | 87ada0a81c46c0fded4dd4c057dece3d80f49e76 /libavformat | |
parent | 43c3cebbd4c09dd4d2f9122b38f23eddfe7cadbe (diff) | |
download | ffmpeg-f3ca3e7f19c86563c2d3bca82962567396b1cc13.tar.gz |
avformat/matroskadec: Remove redundant initialization
Every new element of an EbmlList is zeroed initially in
ebml_parse_elem, so that in particular a SimpleBlock's duration is
initialized to zero. Therefore it is unnecessary to initialize this
field again (for SimpleBlocks) in matroska_parse_cluster_incremental.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/matroskadec.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index d516ef37c7..b594bc4a95 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -3491,8 +3491,7 @@ static int matroska_parse_cluster(MatroskaDemuxContext *matroska) int is_keyframe = blocks[i].non_simple ? blocks[i].reference == INT64_MIN : -1; uint8_t* additional = blocks[i].additional.size > 0 ? blocks[i].additional.data : NULL; - if (!blocks[i].non_simple) - blocks[i].duration = 0; + res = matroska_parse_block(matroska, blocks[i].bin.buf, blocks[i].bin.data, blocks[i].bin.size, blocks[i].bin.pos, matroska->current_cluster.timecode, |