diff options
author | Marton Balint <cus@passwd.hu> | 2023-12-29 13:41:42 +0100 |
---|---|---|
committer | Marton Balint <cus@passwd.hu> | 2024-01-07 22:47:22 +0100 |
commit | 363b3ec98a0fd49ca9144ac1b16c272a14e1b0df (patch) | |
tree | 4cf6e25183ca7cb05df6db0344bc8f7e7550950a /libavcodec | |
parent | e4c96dc96ccea3c74373b5be5bacd94049b429e2 (diff) | |
download | ffmpeg-363b3ec98a0fd49ca9144ac1b16c272a14e1b0df.tar.gz |
all: use av_channel_layout_describe_bprint instead of av_channel_layout_describe in a few places
Where an AVBPrint buffer is used later anyway.
Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/avcodec.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/libavcodec/avcodec.c b/libavcodec/avcodec.c index 2dda310e91..a6c8629f6c 100644 --- a/libavcodec/avcodec.c +++ b/libavcodec/avcodec.c @@ -656,12 +656,7 @@ void avcodec_string(char *buf, int buf_size, AVCodecContext *enc, int encode) if (enc->sample_rate) { av_bprintf(&bprint, "%d Hz, ", enc->sample_rate); } - { - char buf[512]; - int ret = av_channel_layout_describe(&enc->ch_layout, buf, sizeof(buf)); - if (ret >= 0) - av_bprintf(&bprint, "%s", buf); - } + av_channel_layout_describe_bprint(&enc->ch_layout, &bprint); if (enc->sample_fmt != AV_SAMPLE_FMT_NONE && (str = av_get_sample_fmt_name(enc->sample_fmt))) { av_bprintf(&bprint, ", %s", str); |