mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-28 08:10:09 +01:00
lavapipe: Properly clean up vk_device
Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>
This commit is contained in:
parent
62f966cf44
commit
b283965427
1 changed files with 2 additions and 0 deletions
|
|
@ -947,6 +947,7 @@ VkResult lvp_CreateDevice(
|
|||
const char *ext_name = pCreateInfo->ppEnabledExtensionNames[i];
|
||||
int index = lvp_get_device_extension_index(ext_name);
|
||||
if (index < 0 || !physical_device->supported_extensions.extensions[index]) {
|
||||
vk_device_finish(&device->vk);
|
||||
vk_free(&device->vk.alloc, device);
|
||||
return vk_error(physical_device->instance, VK_ERROR_EXTENSION_NOT_PRESENT);
|
||||
}
|
||||
|
|
@ -973,6 +974,7 @@ void lvp_DestroyDevice(
|
|||
LVP_FROM_HANDLE(lvp_device, device, _device);
|
||||
|
||||
lvp_queue_finish(&device->queue);
|
||||
vk_device_finish(&device->vk);
|
||||
vk_free(&device->vk.alloc, device);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue