diff options
author | Pan Bian <bianpan2016@163.com> | 2017-11-27 11:13:05 +0800 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2017-11-28 21:42:48 +0100 |
commit | f63450c8e4c9c1f7af07869c4a25543e4e4d2626 (patch) | |
tree | d65e36e10a7d6a92d89e10b1fae5e9a7b2461513 /libavformat/mov.c | |
parent | 3f81259f337ba57ab1a722566c8d8122dc705823 (diff) | |
download | ffmpeg-f63450c8e4c9c1f7af07869c4a25543e4e4d2626.tar.gz |
avformat/mov: return correct value in mov_read_cmov
On some failure paths, the error code is not correctly set.
Signed-off-by: Pan Bian <bianpan2016@163.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavformat/mov.c')
-rw-r--r-- | libavformat/mov.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c index 230a7f95d0..c9018592e0 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -4894,6 +4894,7 @@ static int mov_read_cmov(MOVContext *c, AVIOContext *pb, MOVAtom atom) if (ret < 0) goto free_and_return; + ret = AVERROR_INVALIDDATA; if (uncompress (moov_data, (uLongf *) &moov_len, (const Bytef *)cmov_data, cmov_len) != Z_OK) goto free_and_return; if (ffio_init_context(&ctx, moov_data, moov_len, 0, NULL, NULL, NULL, NULL) != 0) |