[FFmpeg-devel] [PATCH 2/2] fftools/textformat: renamings in print_unit_int for consistency (cosmetic)
Marvin Scholz
epirat07 at gmail.com
Fri Jun 27 01:27:29 EEST 2025
On 23 Jun 2025, at 0:10, softworkz . wrote:
>> -----Original Message-----
>> From: ffmpeg-devel <ffmpeg-devel-bounces at ffmpeg.org> On Behalf Of
>> Nicolas Gaullier
>> Sent: Freitag, 20. Juni 2025 13:08
>> To: ffmpeg-devel at ffmpeg.org
>> Cc: Nicolas Gaullier <nicolas.gaullier at cji.paris>
>> Subject: [FFmpeg-devel] [PATCH 2/2] fftools/textformat: renamings
>> in print_unit_int for consistency (cosmetic)
>>
>> Signed-off-by: Nicolas Gaullier <nicolas.gaullier at cji.paris>
>> ---
>> fftools/ffprobe.c | 2 +-
>> fftools/graph/graphprint.c | 2 +-
>> fftools/textformat/avtextformat.c | 4 ++--
>> fftools/textformat/avtextformat.h | 2 +-
>> 4 files changed, 5 insertions(+), 5 deletions(-)
>>
>> diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c
>> index 1346ed33c5..e8cde01407 100644
>> --- a/fftools/ffprobe.c
>> +++ b/fftools/ffprobe.c
>> @@ -429,7 +429,7 @@ static void log_callback(void *ptr, int level,
>> const char *fmt, va_list vl)
>> #define print_ts(k, v) avtext_print_ts(tfc, k, v, 0)
>> #define print_duration_time(k, v, tb) avtext_print_time(tfc, k, v,
>> tb, 1)
>> #define print_duration_ts(k, v) avtext_print_ts(tfc, k, v,
>> 1)
>> -#define print_val(k, v, u) avtext_print_unit_int(tfc, k, v,
>> u)
>> +#define print_val(k, v, u) avtext_print_unit_integer(tfc, k,
>> v, u)
>>
>> #define REALLOCZ_ARRAY_STREAM(ptr, cur_n, new_n)
>> \
>> {
>> \
>> diff --git a/fftools/graph/graphprint.c
>> b/fftools/graph/graphprint.c
>> index e4c6886cf8..242eaf8ba1 100644
>> --- a/fftools/graph/graphprint.c
>> +++ b/fftools/graph/graphprint.c
>> @@ -140,7 +140,7 @@ typedef struct GraphPrintContext {
>> #define print_q(k, v, s) avtext_print_rational(tfc, k, v,
>> s)
>> #define print_str(k, v) avtext_print_string(tfc, k, v, 0)
>> #define print_str_opt(k, v) avtext_print_string(tfc, k, v,
>> gpc->opt_flags)
>> -#define print_val(k, v, u) avtext_print_unit_int(tfc, k, v,
>> u)
>> +#define print_val(k, v, u) avtext_print_unit_integer(tfc, k,
>> v, u)
>>
>> #define print_fmt(k, f, ...) do { \
>> av_bprint_clear(&gpc->pbuf); \
>> diff --git a/fftools/textformat/avtextformat.c
>> b/fftools/textformat/avtextformat.c
>> index 14bad9022b..396fe2f853 100644
>> --- a/fftools/textformat/avtextformat.c
>> +++ b/fftools/textformat/avtextformat.c
>> @@ -437,11 +437,11 @@ static char *value_string(const
>> AVTextFormatContext *tctx, char *buf, int buf_si
>> }
>>
>>
>> -void avtext_print_unit_int(AVTextFormatContext *tctx, const char
>> *key, int64_t value, const char *unit)
>> +void avtext_print_unit_integer(AVTextFormatContext *tctx, const
>> char *key, int64_t val, const char *unit)
>> {
>> char val_str[128];
>> struct unit_value uv;
>> - uv.val.i = value;
>> + uv.val.i = val;
>> uv.unit = unit;
>> avtext_print_string(tctx, key, value_string(tctx, val_str,
>> sizeof(val_str), uv), 0);
>> }
>> diff --git a/fftools/textformat/avtextformat.h
>> b/fftools/textformat/avtextformat.h
>> index 8316829af5..d9c14069eb 100644
>> --- a/fftools/textformat/avtextformat.h
>> +++ b/fftools/textformat/avtextformat.h
>> @@ -169,7 +169,7 @@ void avtext_print_integer(AVTextFormatContext
>> *tctx, const char *key, int64_t va
>>
>> int avtext_print_string(AVTextFormatContext *tctx, const char
>> *key, const char *val, int flags);
>>
>> -void avtext_print_unit_int(AVTextFormatContext *tctx, const char
>> *key, int64_t value, const char *unit);
>> +void avtext_print_unit_integer(AVTextFormatContext *tctx, const
>> char *key, int64_t val, const char *unit);
>>
>> void avtext_print_rational(AVTextFormatContext *tctx, const char
>> *key, AVRational q, char sep);
>>
>> --
>
> Hi Nicolas,
>
> thanks for the patch. Makes sense and
> LGTM.
>
> softworkz
>
Pushed as 18c62245d7883c28d3f8ee5fa587b45fd2e82013.
Thanks.
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".
More information about the ffmpeg-devel
mailing list