diff options
author | Leo Liu <[email protected]> | 2016-07-11 15:27:16 -0400 |
---|---|---|
committer | Leo Liu <[email protected]> | 2016-07-15 09:17:36 -0400 |
commit | b9d10e79c88842ba05d6937a3803cb5740b866da (patch) | |
tree | 49423f1c0b998fe23f90a38d945bc0b77cfb08ba /src/gallium | |
parent | ea6b236ab1a53cc0a616088aec4a0ec4d804f77d (diff) |
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 <[email protected]>
Cc: "12.0" <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/state_trackers/omx/vid_enc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/state_trackers/omx/vid_enc.c b/src/gallium/state_trackers/omx/vid_enc.c index bbc7941ffe0..642238e53f0 100644 --- a/src/gallium/state_trackers/omx/vid_enc.c +++ b/src/gallium/state_trackers/omx/vid_enc.c @@ -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); |