mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
lavapipe: fix a leak on a lvp_image_create exit path
This traces back toc688f8f8c5, but the shape of the fix would be different if against that. So we do the optimal for the current code flow and only port to stable. Cc: mesa-stable Reviewed-by: Lucas Fryzek <lfryzek@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36335> (cherry picked from commit16e3293c31)
This commit is contained in:
parent
e25c0a8955
commit
bb04c93d2e
2 changed files with 5 additions and 3 deletions
|
|
@ -2064,7 +2064,7 @@
|
|||
"description": "lavapipe: fix a leak on a lvp_image_create exit path",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null,
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -184,8 +184,10 @@ lvp_image_create(VkDevice _device,
|
|||
&template,
|
||||
&image->planes[p].size);
|
||||
}
|
||||
if (!image->planes[p].bo)
|
||||
return vk_error(device, VK_ERROR_OUT_OF_HOST_MEMORY);
|
||||
if (!image->planes[p].bo) {
|
||||
result = vk_error(device, VK_ERROR_OUT_OF_HOST_MEMORY);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
image->planes[p].size = align64(image->planes[p].size, image->alignment);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue