projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1492904
)
vk: Fix result of vkCreateInstance
author
Chad Versace
<chad.versace@intel.com>
Thu, 21 May 2015 02:51:10 +0000
(19:51 -0700)
committer
Chad Versace
<chad.versace@intel.com>
Thu, 21 May 2015 02:51:10 +0000
(19:51 -0700)
When fill_physical_device() fails, don't return VK_SUCCESS.
src/vulkan/device.c
patch
|
blob
|
history
diff --git
a/src/vulkan/device.c
b/src/vulkan/device.c
index f6578d01341378ce2062763e2086da05a9872339..3c245cd036bc61caca47a1209986d943f63a7eb6 100644
(file)
--- a/
src/vulkan/device.c
+++ b/
src/vulkan/device.c
@@
-142,9
+142,11
@@
VkResult anv_CreateInstance(
instance->physicalDeviceCount = 0;
result = fill_physical_device(&instance->physicalDevice,
instance, "/dev/dri/renderD128");
- if (result == VK_SUCCESS)
- instance->physicalDeviceCount++;
+ if (result != VK_SUCCESS)
+ return result;
+
+ instance->physicalDeviceCount++;
*pInstance = (VkInstance) instance;
return VK_SUCCESS;