[FFmpeg-cvslog] avcodec/ttmlenc: Remove always-true check

Andreas Rheinhardt git at videolan.org
Thu Feb 22 02:54:16 EET 2024


ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Sun Feb 18 01:27:23 2024 +0100| [ed9de6d2d8cb82cd646a18c0d0c745a65c96f2cc] | committer: Andreas Rheinhardt

avcodec/ttmlenc: Remove always-true check

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ed9de6d2d8cb82cd646a18c0d0c745a65c96f2cc
---

 libavcodec/ttmlenc.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/libavcodec/ttmlenc.c b/libavcodec/ttmlenc.c
index f48274d2ea..779cb75199 100644
--- a/libavcodec/ttmlenc.c
+++ b/libavcodec/ttmlenc.c
@@ -351,9 +351,8 @@ static int ttml_write_header_content(AVCodecContext *avctx)
     memcpy(avctx->extradata, TTMLENC_EXTRADATA_SIGNATURE,
            TTMLENC_EXTRADATA_SIGNATURE_SIZE);
 
-    if (additional_extradata_size)
-        memcpy(avctx->extradata + TTMLENC_EXTRADATA_SIGNATURE_SIZE,
-               s->buffer.str, additional_extradata_size);
+    memcpy(avctx->extradata + TTMLENC_EXTRADATA_SIGNATURE_SIZE,
+           s->buffer.str, additional_extradata_size);
 
     ret = 0;
 fail:



More information about the ffmpeg-cvslog mailing list