avcodec/libaribb24,ttmlenc, avutil/tx: Remove redundant init of AVBPrint

An AVBPrint is initialized via av_bprint_init() (or
av_bprint_init_for_buffer()) which expects uninitialized
AVBPrints; it is therefore not necessary to zero them before
the actual initialization.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
Andreas Rheinhardt 2023-09-11 16:08:05 +02:00
parent 830b5cc35e
commit c1714a483f
3 changed files with 4 additions and 4 deletions

View File

@ -227,7 +227,7 @@ static int libaribb24_handle_regions(AVCodecContext *avctx, AVSubtitle *sub)
Libaribb24Context *b24 = avctx->priv_data;
const arib_buf_region_t *region = arib_decoder_get_regions(b24->decoder);
unsigned int profile_font_size = get_profile_font_size(avctx);
AVBPrint buf = { 0 };
AVBPrint buf;
int ret = 0;
av_bprint_init(&buf, 0, AV_BPRINT_SIZE_UNLIMITED);

View File

@ -45,7 +45,7 @@ typedef struct {
static void ttml_text_cb(void *priv, const char *text, int len)
{
TTMLContext *s = priv;
AVBPrint cur_line = { 0 };
AVBPrint cur_line;
AVBPrint *buffer = &s->buffer;
av_bprint_init(&cur_line, len, AV_BPRINT_SIZE_UNLIMITED);

View File

@ -595,7 +595,7 @@ static void print_type(AVBPrint *bp, enum AVTXType type)
static void print_cd_info(const FFTXCodelet *cd, int prio, int len, int print_prio)
{
AVBPrint bp = { 0 };
AVBPrint bp;
av_bprint_init(&bp, 0, AV_BPRINT_SIZE_AUTOMATIC);
av_bprintf(&bp, "%s - type: ", cd->name);
@ -718,7 +718,7 @@ av_cold int ff_tx_init_subtx(AVTXContext *s, enum AVTXType type,
int codelet_list_idx = codelet_list_num;
int nb_cd_matches = 0;
#if !CONFIG_SMALL
AVBPrint bp = { 0 };
AVBPrint bp;
#endif
/* We still accept functions marked with SLOW, even if the CPU is