aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/av1.c
diff options
context:
space:
mode:
authorJeremy Dorfman via ffmpeg-devel <ffmpeg-devel@ffmpeg.org>2019-04-08 08:14:27 -0400
committerJames Almer <jamrial@gmail.com>2019-04-08 11:24:53 -0300
commitbb5efd1727eeecc9be8f1402810c7ab72344eed3 (patch)
tree6cb2e63c0aa417a13f1999f33565d7283b3fd9af /libavformat/av1.c
parentecdaa4b4fa5272d6798ddaec0b3b719ac0d512c1 (diff)
downloadffmpeg-bb5efd1727eeecc9be8f1402810c7ab72344eed3.tar.gz
avformat/av1: Initialize padding in ff_isom_write_av1c
Otherwise, AV1 encodes with FFmpeg trigger use-of-uninitialized-value warnings under MemorySanitizer, and the output buffer potentially changes from run to run. Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavformat/av1.c')
-rw-r--r--libavformat/av1.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavformat/av1.c b/libavformat/av1.c
index a0aad436a6..5fde8df97e 100644
--- a/libavformat/av1.c
+++ b/libavformat/av1.c
@@ -372,6 +372,7 @@ int ff_isom_write_av1c(AVIOContext *pb, const uint8_t *buf, int size)
put_bits(&pbc, 1, seq_params.chroma_subsampling_x);
put_bits(&pbc, 1, seq_params.chroma_subsampling_y);
put_bits(&pbc, 2, seq_params.chroma_sample_position);
+ put_bits(&pbc, 8, 0); // padding
flush_put_bits(&pbc);
avio_write(pb, header, sizeof(header));