nvk: Fix uninitialized result usage in NVK_DEBUG_ZERO_MEMORY.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
This commit is contained in:
Emma Anholt 2022-09-10 22:22:12 -07:00 committed by Marge Bot
parent 5d0aa694ee
commit 2773e55e86

View file

@ -121,8 +121,9 @@ nvk_allocate_memory(struct nvk_device *device,
}
memset(map, 0, mem->bo->size);
nouveau_ws_bo_unmap(mem->bo, map);
result = VK_SUCCESS;
} else {
VkResult result = zero_vram(device, mem->bo);
result = zero_vram(device, mem->bo);
if (result != VK_SUCCESS)
goto fail_bo;
}