diff options
author | Timo Rothenpieler <timo@rothenpieler.org> | 2016-11-29 17:37:13 +0100 |
---|---|---|
committer | Timo Rothenpieler <timo@rothenpieler.org> | 2016-11-30 12:36:23 +0100 |
commit | 52773a2c68bd8941fbe901e311224e49f2dc8ffe (patch) | |
tree | 97482577b779bd8b06b70e530809abb7d11d580f | |
parent | 88281a5256f0034451c09acab3aff44acb43c2a3 (diff) | |
download | ffmpeg-streaming-52773a2c68bd8941fbe901e311224e49f2dc8ffe.zip ffmpeg-streaming-52773a2c68bd8941fbe901e311224e49f2dc8ffe.tar.gz |
avutil/hwcontext_cuda: check for missing pixel format
-rw-r--r-- | libavutil/hwcontext_cuda.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavutil/hwcontext_cuda.c b/libavutil/hwcontext_cuda.c index 2ebf4bc..5dd0d99 100644 --- a/libavutil/hwcontext_cuda.c +++ b/libavutil/hwcontext_cuda.c @@ -117,6 +117,9 @@ static int cuda_frames_init(AVHWFramesContext *ctx) case AV_PIX_FMT_P016: size = aligned_width * ctx->height * 3; break; + default: + av_log(ctx, AV_LOG_ERROR, "BUG: Pixel format missing from size calculation."); + return AVERROR_BUG; } ctx->internal->pool_internal = av_buffer_pool_init2(size, ctx, cuda_pool_alloc, NULL); |