---
is the tag of the commit message correct? apc?
libavformat/apc.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libavformat/apc.c b/libavformat/apc.c
index 0b6c583..5d3453c 100644
--- a/libavformat/apc.c
+++ b/libavformat/apc.c
@@ -54,8 +54,11 @@ static int apc_read_header(AVFormatContext *s)
st->codec->extradata_size = 2 * 4;
st->codec->extradata = av_malloc(st->codec->extradata_size +
FF_INPUT_BUFFER_PADDING_SIZE);
- if (!st->codec->extradata)
+ if (!st->codec->extradata) {
+ avformat_free_context(s);
+ st->codec->extradata_size = 0;
return AVERROR(ENOMEM);
+ }
/* initial predictor values for adpcm decoder */
avio_read(pb, st->codec->extradata, 2 * 4);
--
1.9.1
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel