mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-11-30 13:24:10 +01:00
[dxvk] Free memory if vkMapMemory fails
Otherwise, we leak the allocated memory chunk and make the problem even worse than it already is.
This commit is contained in:
parent
1dadba3cce
commit
cb806a5d56
@ -340,6 +340,7 @@ namespace dxvk {
|
||||
|
||||
if (status != VK_SUCCESS) {
|
||||
Logger::err(str::format("DxvkMemoryAllocator: Mapping memory failed with ", status));
|
||||
m_vkd->vkFreeMemory(m_vkd->device(), result.memHandle, nullptr);
|
||||
return DxvkDeviceMemory();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user