Message ID | 20231003230423.951161-1-vigneshv@google.com |
---|---|
State | Accepted |
Commit | 9132a0fbe25d472952872c67abe818aec5d64e4a |
Headers | show |
Series | [FFmpeg-devel] avformat/mov: Disallow more than one meta box for AVIF | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
yinshiyou/make_loongarch64 | warning | New warnings during build |
On Tue, Oct 3, 2023 at 7:05 PM Vignesh Venkatasubramanian via ffmpeg-devel < ffmpeg-devel@ffmpeg.org> wrote: > This is not allowed per the spec. > > Signed-off-by: Vignesh Venkatasubramanian <vigneshv@google.com> > --- > libavformat/mov.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/libavformat/mov.c b/libavformat/mov.c > index 294c864fbd..a8f57f9281 100644 > --- a/libavformat/mov.c > +++ b/libavformat/mov.c > @@ -4892,6 +4892,8 @@ static int avif_add_stream(MOVContext *c, int > item_id) > { > MOVStreamContext *sc; > AVStream *st; > + if (c->fc->nb_streams) > + return AVERROR_INVALIDDATA; > int item_index = -1; > for (int i = 0; i < c->avif_info_size; i++) > if (c->avif_info[i].item_id == item_id) { > -- > lgtm
diff --git a/libavformat/mov.c b/libavformat/mov.c index 294c864fbd..a8f57f9281 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -4892,6 +4892,8 @@ static int avif_add_stream(MOVContext *c, int item_id) { MOVStreamContext *sc; AVStream *st; + if (c->fc->nb_streams) + return AVERROR_INVALIDDATA; int item_index = -1; for (int i = 0; i < c->avif_info_size; i++) if (c->avif_info[i].item_id == item_id) {
This is not allowed per the spec. Signed-off-by: Vignesh Venkatasubramanian <vigneshv@google.com> --- libavformat/mov.c | 2 ++ 1 file changed, 2 insertions(+)