libavformat/lafdec: free data

Fixes: memleak

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
release/6.0
Michael Niedermayer 2 years ago
parent ad95d9c855
commit f4b4e16641
No known key found for this signature in database
GPG Key ID: B18E8928B3948D64
  1. 11
      libavformat/lafdec.c

@ -252,6 +252,15 @@ again:
return 0;
}
static int laf_read_close(AVFormatContext *ctx)
{
LAFContext *s = ctx->priv_data;
av_freep(&s->data);
return 0;
}
static int laf_read_seek(AVFormatContext *ctx, int stream_index,
int64_t timestamp, int flags)
{
@ -269,7 +278,9 @@ const AVInputFormat ff_laf_demuxer = {
.read_probe = laf_probe,
.read_header = laf_read_header,
.read_packet = laf_read_packet,
.read_close = laf_read_close,
.read_seek = laf_read_seek,
.extensions = "laf",
.flags = AVFMT_GENERIC_INDEX,
.flags_internal = FF_FMT_INIT_CLEANUP,
};

Loading…
Cancel
Save