lavc/decode: drop a useless warning

Decoders will currently warn if an audio decoder not marked with
AV_CODEC_CAP_SUBFRAMES consumes less than the whole packet, but
* this happens for regular files
* this has no negative consequences
* there is no meeaningful action that can or should be taken in response

The warning is thus useless noise.
This commit is contained in:
Anton Khirnov 2023-05-09 12:16:45 +02:00
parent 954d16fa3f
commit 51d6ae099f
2 changed files with 0 additions and 9 deletions

View File

@ -423,13 +423,6 @@ FF_ENABLE_DEPRECATION_WARNINGS
} }
} }
if (avctx->codec->type == AVMEDIA_TYPE_AUDIO &&
!avci->showed_multi_packet_warning &&
ret >= 0 && ret != pkt->size && !(avctx->codec->capabilities & AV_CODEC_CAP_SUBFRAMES)) {
av_log(avctx, AV_LOG_WARNING, "Multiple frames in a packet.\n");
avci->showed_multi_packet_warning = 1;
}
if (!got_frame) if (!got_frame)
av_frame_unref(frame); av_frame_unref(frame);

View File

@ -148,8 +148,6 @@ typedef struct AVCodecInternal {
AVFrame *buffer_frame; AVFrame *buffer_frame;
int draining_done; int draining_done;
int showed_multi_packet_warning;
/* to prevent infinite loop on errors when draining */ /* to prevent infinite loop on errors when draining */
int nb_draining_errors; int nb_draining_errors;