diff options
author | Marton Balint <cus@passwd.hu> | 2023-01-24 00:35:54 +0100 |
---|---|---|
committer | Marton Balint <cus@passwd.hu> | 2023-02-13 00:36:46 +0100 |
commit | 6b6f7db81932f94876ff4bcfd2da0582b8ab897e (patch) | |
tree | 6aaa307f71042d91c6b19736f1cdc6498fd794e5 /libavcodec/atrac3plus.c | |
parent | e506ea3ce1de0c782b2b833398240c8e19a02bb4 (diff) | |
download | ffmpeg-6b6f7db81932f94876ff4bcfd2da0582b8ab897e.tar.gz |
avcodec: add AVCodecContext.frame_num as 64 bit variant to frame_number
Frame counters can overflow relatively easily (INT_MAX number of frames is
slightly more than 1 year for 60 fps content), so make sure we use 64 bit
values for them.
Also deprecate the old 32 bit frame_number attribute.
Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'libavcodec/atrac3plus.c')
-rw-r--r-- | libavcodec/atrac3plus.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/atrac3plus.c b/libavcodec/atrac3plus.c index a0836f1178..5661654ce3 100644 --- a/libavcodec/atrac3plus.c +++ b/libavcodec/atrac3plus.c @@ -1391,9 +1391,9 @@ static int decode_band_numwavs(GetBitContext *gb, Atrac3pChanUnitCtx *ctx, if (band_has_tones[sb]) { if (ctx->waves_info->tones_index + dst[sb].num_wavs > 48) { av_log(avctx, AV_LOG_ERROR, - "Too many tones: %d (max. 48), frame: %d!\n", + "Too many tones: %d (max. 48), frame: %"PRId64"!\n", ctx->waves_info->tones_index + dst[sb].num_wavs, - avctx->frame_number); + avctx->frame_num); return AVERROR_INVALIDDATA; } dst[sb].start_index = ctx->waves_info->tones_index; |