Issue detected by Coverity
If the FEI mode is not handled the created resources should be
released and return and error code.
The system resource will not be reclaimed and reused, reducing the
future availability of the resource.
In gst_vaapi_encoder_h264_fei_encode: Leak of memory or pointers to
system resources
g_array_free (info_to_pak.h264_slice_headers, TRUE);
gst_vaapi_enc_picture_unref (picture2);
-
+ } else {
+ GST_ERROR ("invalid FEI mode");
+ goto error;
}
return GST_VAAPI_ENCODER_STATUS_SUCCESS;