Browse Source

avformat/flic: se av_freep() to avoid leaving stale extradata pointer

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n2.6
Michael Niedermayer 10 years ago
parent
commit
480cd822b3
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavformat/flic.c

+ 1
- 1
libavformat/flic.c View File

@@ -175,7 +175,7 @@ static int flic_read_header(AVFormatContext *s)
avio_seek(pb, 12, SEEK_SET); avio_seek(pb, 12, SEEK_SET);


/* send over abbreviated FLIC header chunk */ /* send over abbreviated FLIC header chunk */
av_free(st->codec->extradata);
av_freep(&st->codec->extradata);
if (ff_alloc_extradata(st->codec, 12)) if (ff_alloc_extradata(st->codec, 12))
return AVERROR(ENOMEM); return AVERROR(ENOMEM);
memcpy(st->codec->extradata, header, 12); memcpy(st->codec->extradata, header, 12);


Loading…
Cancel
Save