diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2021-04-29 23:44:27 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2021-06-08 12:52:49 +0200 |
commit | 7a57c5ab915a26afd03447ba130cf88c5f8dca77 (patch) | |
tree | e1a645e693b3be90235f8d084003426131633d83 | |
parent | 964c826f5507978e76c4b9fe5f5ad976909f273e (diff) | |
download | ffmpeg-7a57c5ab915a26afd03447ba130cf88c5f8dca77.tar.gz |
avcodec/omx: Zero packet padding
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
-rw-r--r-- | libavcodec/omx.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/omx.c b/libavcodec/omx.c index ddb3ba4f66..9597c60057 100644 --- a/libavcodec/omx.c +++ b/libavcodec/omx.c @@ -871,6 +871,7 @@ static int omx_encode_frame(AVCodecContext *avctx, AVPacket *pkt, memcpy(s->output_buf + s->output_buf_size, buffer->pBuffer + buffer->nOffset, buffer->nFilledLen); s->output_buf_size += buffer->nFilledLen; if (buffer->nFlags & OMX_BUFFERFLAG_ENDOFFRAME) { + memset(s->output_buf + s->output_buf_size, 0, AV_INPUT_BUFFER_PADDING_SIZE); if ((ret = av_packet_from_data(pkt, s->output_buf, s->output_buf_size)) < 0) { av_freep(&s->output_buf); s->output_buf_size = 0; |