aboutsummaryrefslogtreecommitdiff
path: root/layers/core_validation.cpp
diff options
context:
space:
mode:
authorTobin Ehlis <tobine@google.com>2016-07-07 12:04:20 -0600
committerTobin Ehlis <tobine@google.com>2016-07-07 13:43:00 -0600
commitb01e0dc6ffd3d718f26766a39649092ae0219b28 (patch)
tree84349c4e225ecdd082edbaac46f99b1d476cdc69 /layers/core_validation.cpp
parent3a15cc6e35b0bf2182da140bc6c984765d03f74c (diff)
downloadusermoji-b01e0dc6ffd3d718f26766a39649092ae0219b28.tar.xz
layers: Remove entries from pipelineLayoutMap
When VkPipelineLayout objects are destroyed, remove their corresponding map entries.
Diffstat (limited to 'layers/core_validation.cpp')
-rw-r--r--layers/core_validation.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp
index 4f94fdb4..13f2f488 100644
--- a/layers/core_validation.cpp
+++ b/layers/core_validation.cpp
@@ -5342,9 +5342,10 @@ DestroyPipeline(VkDevice device, VkPipeline pipeline, const VkAllocationCallback
VKAPI_ATTR void VKAPI_CALL
DestroyPipelineLayout(VkDevice device, VkPipelineLayout pipelineLayout, const VkAllocationCallbacks *pAllocator) {
- get_my_data_ptr(get_dispatch_key(device), layer_data_map)
- ->device_dispatch_table->DestroyPipelineLayout(device, pipelineLayout, pAllocator);
- // TODO : Clean up any internal data structures using this obj.
+ layer_data *dev_data = get_my_data_ptr(get_dispatch_key(device), layer_data_map);
+ dev_data->device_dispatch_table->DestroyPipelineLayout(device, pipelineLayout, pAllocator);
+
+ dev_data->pipelineLayoutMap.erase(pipelineLayout);
}
VKAPI_ATTR void VKAPI_CALL