aboutsummaryrefslogtreecommitdiff
path: root/layers
diff options
context:
space:
mode:
authorMark Lobodzinski <mark@lunarg.com>2017-06-12 10:19:26 -0600
committerMark Lobodzinski <mark@lunarg.com>2017-06-12 12:10:09 -0600
commitfa3003ba767c05d3ea1539f242885189ddf3a259 (patch)
tree7c7dca86c29a8697efe3e07d8857ce5a69a60e58 /layers
parentec663d87613fec42b95c656132ec38e30c222f55 (diff)
downloadusermoji-fa3003ba767c05d3ea1539f242885189ddf3a259.tar.xz
layers: Add in missing CreatDevice physdev obj check
Prevents doc validator from failing. Change-Id: I0e70da954f0a7d7ed4a54d4bcefe996a6cc9cfb3
Diffstat (limited to 'layers')
-rw-r--r--layers/object_tracker.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/layers/object_tracker.cpp b/layers/object_tracker.cpp
index a4acc720..1265524a 100644
--- a/layers/object_tracker.cpp
+++ b/layers/object_tracker.cpp
@@ -3282,6 +3282,10 @@ VKAPI_ATTR VkResult VKAPI_CALL CreateDisplayPlaneSurfaceKHR(VkInstance instance,
VKAPI_ATTR VkResult VKAPI_CALL CreateDevice(VkPhysicalDevice physicalDevice, const VkDeviceCreateInfo *pCreateInfo,
const VkAllocationCallbacks *pAllocator, VkDevice *pDevice) {
std::lock_guard<std::mutex> lock(global_lock);
+ bool skip = ValidateObject(physicalDevice, physicalDevice, kVulkanObjectTypePhysicalDevice, false, VALIDATION_ERROR_1fc27a01,
+ VALIDATION_ERROR_UNDEFINED);
+ if (skip) return VK_ERROR_VALIDATION_FAILED_EXT;
+
layer_data *phy_dev_data = GetLayerDataPtr(get_dispatch_key(physicalDevice), layer_data_map);
VkLayerDeviceCreateInfo *chain_info = get_chain_info(pCreateInfo, VK_LAYER_LINK_INFO);