vaapi_encode_h265: Add missing error return
authorMark Thompson <sw@jkqxz.net>
Mon, 24 Sep 2018 22:02:10 +0000 (23:02 +0100)
committerMark Thompson <sw@jkqxz.net>
Mon, 24 Sep 2018 22:09:45 +0000 (23:09 +0100)
Fixes CID #1439657.

libavcodec/vaapi_encode_h265.c

index 1ada973..10312fb 100644 (file)
@@ -293,6 +293,7 @@ static int vaapi_encode_h265_init_sequence_params(AVCodecContext *avctx)
         } else {
             av_log(avctx, AV_LOG_ERROR, "Chroma format of input pixel format "
                    "%s is not supported.\n", desc->name);
+            return AVERROR(EINVAL);
         }
     }
     bit_depth = desc->comp[0].depth;