diff options
author | Limin Wang <lance.lmwang@gmail.com> | 2020-04-18 07:52:49 +0300 |
---|---|---|
committer | Limin Wang <lance.lmwang@gmail.com> | 2020-05-08 01:42:25 +0300 |
commit | 8b077511238e97d8657fb58551befc63cf5e29ed (patch) | |
tree | ad5be65db141a5aa63a89d1d51125c8f030d55bc /libavcodec/libx264.c | |
parent | f5e33514e7a879b09fabfeffd78402590225bf47 (diff) |
avcodec/libx264: return error if unknown picture type encountered
Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
Diffstat (limited to 'libavcodec/libx264.c')
-rw-r--r-- | libavcodec/libx264.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c index c13e8a58d4..4121b2807a 100644 --- a/libavcodec/libx264.c +++ b/libavcodec/libx264.c @@ -476,7 +476,8 @@ static int X264_frame(AVCodecContext *ctx, AVPacket *pkt, const AVFrame *frame, pict_type = AV_PICTURE_TYPE_B; break; default: - pict_type = AV_PICTURE_TYPE_NONE; + av_log(ctx, AV_LOG_ERROR, "Unknown picture type encountered.\n"); + return AVERROR_EXTERNAL; } #if FF_API_CODED_FRAME FF_DISABLE_DEPRECATION_WARNINGS |