Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/matroskadec.c')
-rw-r--r--libavformat/matroskadec.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
index e376baeac2..d5bc9230bb 100644
--- a/libavformat/matroskadec.c
+++ b/libavformat/matroskadec.c
@@ -746,11 +746,9 @@ static int ebml_read_ascii(AVIOContext *pb, int size, char **str)
static int ebml_read_binary(AVIOContext *pb, int length, EbmlBin *bin)
{
av_free(bin->data);
- if (!(bin->data = av_malloc(length + FF_INPUT_BUFFER_PADDING_SIZE)))
+ if (!(bin->data = av_mallocz(length + FF_INPUT_BUFFER_PADDING_SIZE)))
return AVERROR(ENOMEM);
- memset(bin->data + length, 0, FF_INPUT_BUFFER_PADDING_SIZE);
-
bin->size = length;
bin->pos = avio_tell(pb);
if (avio_read(pb, bin->data, length) != length) {