Fix ineffective error code checks.
diff --git a/include/vk_mem_alloc.h b/include/vk_mem_alloc.h
index b9317de..39f6ef3 100644
--- a/include/vk_mem_alloc.h
+++ b/include/vk_mem_alloc.h
@@ -16404,7 +16404,7 @@
pImageCreateInfo,
allocator->GetAllocationCallbacks(),
pImage);
- if(res >= 0)
+ if(res == VK_SUCCESS)
{
VmaSuballocationType suballocType = pImageCreateInfo->tiling == VK_IMAGE_TILING_OPTIMAL ?
VMA_SUBALLOCATION_TYPE_IMAGE_OPTIMAL :
@@ -16429,14 +16429,14 @@
1, // allocationCount
pAllocation);
- if(res >= 0)
+ if(res == VK_SUCCESS)
{
// 3. Bind image with memory.
if((pAllocationCreateInfo->flags & VMA_ALLOCATION_CREATE_DONT_BIND_BIT) == 0)
{
res = allocator->BindImageMemory(*pAllocation, 0, *pImage, VMA_NULL);
}
- if(res >= 0)
+ if(res == VK_SUCCESS)
{
// All steps succeeded.
#if VMA_STATS_STRING_ENABLED