vabasedec: Initialize the allocation related variables in decide_allocation()

Prevent garbage value has been pass thru and causing
pipeline fail to run.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7097>
This commit is contained in:
Lim, Siew Hoon 2024-06-27 13:59:40 +08:00 committed by GStreamer Marge Bot
parent c270c5643d
commit f498ba25da

View file

@ -266,7 +266,7 @@ _decide_allocation_for_video_crop (GstVideoDecoder * decoder,
GstQuery * query, GstCaps * caps)
{
GstAllocator *allocator = NULL, *other_allocator = NULL;
GstAllocationParams other_params, params;
GstAllocationParams other_params = { 0, }, params = { 0, };
gboolean update_pool = FALSE, update_allocator = FALSE;
GstBufferPool *pool = NULL, *other_pool = NULL;
guint size = 0, min, max, usage_hint;
@ -475,7 +475,7 @@ static gboolean
gst_va_base_dec_decide_allocation (GstVideoDecoder * decoder, GstQuery * query)
{
GstAllocator *allocator = NULL, *other_allocator = NULL;
GstAllocationParams other_params, params;
GstAllocationParams other_params = { 0, }, params = { 0, };
GstBufferPool *pool = NULL, *other_pool = NULL;
GstCaps *caps = NULL;
GstVaBaseDec *base = GST_VA_BASE_DEC (decoder);