[FFmpeg-cvslog] Merge commit 'defe307fb22beca60a632e976ab97e5edd4aee25'
James Almer
git at videolan.org
Sat Nov 11 05:29:41 EET 2017
ffmpeg | branch: master | James Almer <jamrial at gmail.com> | Sat Nov 11 00:28:53 2017 -0300| [73198aca2c27712e45f29dec769f4c343ee40c20] | committer: James Almer
Merge commit 'defe307fb22beca60a632e976ab97e5edd4aee25'
* commit 'defe307fb22beca60a632e976ab97e5edd4aee25':
mov: move stsd finalization to an appropriate place
mov: Do not set stsd_count if mov_read_stsd() fails
mov: log and return early on non-positive stsd entry counts
See 8b43ee4054af799e388d380b379a13a60849c1b5
656feb641de3cd5b9cb4e33ffd3f0ad4664c36d2
Merged-by: James Almer <jamrial at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=73198aca2c27712e45f29dec769f4c343ee40c20
---
libavformat/mov.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/libavformat/mov.c b/libavformat/mov.c
index 7954db6e47..5fc597ee26 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -2548,15 +2548,18 @@ static int mov_read_stsd(MOVContext *c, AVIOContext *pb, MOVAtom atom)
/* Prepare space for hosting multiple extradata. */
sc->extradata = av_mallocz_array(entries, sizeof(*sc->extradata));
+ if (!sc->extradata)
+ return AVERROR(ENOMEM);
+
sc->extradata_size = av_mallocz_array(entries, sizeof(*sc->extradata_size));
- if (!sc->extradata_size || !sc->extradata) {
+ if (!sc->extradata_size) {
ret = AVERROR(ENOMEM);
goto fail;
}
ret = ff_mov_read_stsd_entries(c, pb, entries);
if (ret < 0)
- return ret;
+ goto fail;
sc->stsd_count = entries;
======================================================================
More information about the ffmpeg-cvslog
mailing list