st/omx/enc: check uninitialized list from task release
The uninitialized list should be checked and returned. Thank Julien for the notification and suggested fix. Signed-off-by: Leo Liu <leo.liu@amd.com> Cc: "12.0" <mesa-stable@lists.freedesktop.org>
This commit is contained in:
@@ -874,8 +874,8 @@ static void enc_ReleaseTasks(struct list_head *head)
|
||||
{
|
||||
struct encode_task *i, *next;
|
||||
|
||||
if (!head)
|
||||
return;
|
||||
if (!head || !head->next)
|
||||
return;
|
||||
|
||||
LIST_FOR_EACH_ENTRY_SAFE(i, next, head, list) {
|
||||
pipe_resource_reference(&i->bitstream, NULL);
|
||||
|
||||
Reference in New Issue
Block a user