diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c index e9c96108582..90019f2b14a 100644 --- a/src/intel/vulkan/anv_device.c +++ b/src/intel/vulkan/anv_device.c @@ -3098,9 +3098,10 @@ VkResult anv_AllocateMemory( i915_tiling); if (ret) { anv_bo_cache_release(device, &device->bo_cache, mem->bo); - return vk_errorf(device->instance, NULL, - VK_ERROR_OUT_OF_DEVICE_MEMORY, - "failed to set BO tiling: %m"); + result = vk_errorf(device->instance, NULL, + VK_ERROR_OUT_OF_DEVICE_MEMORY, + "failed to set BO tiling: %m"); + goto fail; } } }