mirror of
https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git
synced 2024-11-10 10:41:52 +00:00
Minor fix: Add missing mutex lock to VmaBlockVector::IsEmpty
This commit is contained in:
parent
6d6b0672b5
commit
023976ad24
@ -6265,7 +6265,7 @@ public:
|
||||
|
||||
void GetPoolStats(VmaPoolStats* pStats);
|
||||
|
||||
bool IsEmpty() const { return m_Blocks.empty(); }
|
||||
bool IsEmpty();
|
||||
bool IsCorruptionDetectionEnabled() const;
|
||||
|
||||
VkResult Allocate(
|
||||
@ -11814,6 +11814,12 @@ void VmaBlockVector::GetPoolStats(VmaPoolStats* pStats)
|
||||
}
|
||||
}
|
||||
|
||||
bool VmaBlockVector::IsEmpty()
|
||||
{
|
||||
VmaMutexLockRead lock(m_Mutex, m_hAllocator->m_UseMutex);
|
||||
return m_Blocks.empty();
|
||||
}
|
||||
|
||||
bool VmaBlockVector::IsCorruptionDetectionEnabled() const
|
||||
{
|
||||
const uint32_t requiredMemFlags = VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT | VK_MEMORY_PROPERTY_HOST_COHERENT_BIT;
|
||||
|
Loading…
Reference in New Issue
Block a user