diff options
| author | Mark Lobodzinski <mark@lunarg.com> | 2016-10-07 14:13:38 -0600 |
|---|---|---|
| committer | Mark Lobodzinski <mark@lunarg.com> | 2016-10-07 14:16:56 -0600 |
| commit | 2a078adee47316974d813bb4234d956cb15fdbb0 (patch) | |
| tree | 39685eb324cc2f0f2d78df1b0180067da82ec261 /layers/unique_objects.cpp | |
| parent | 8d02126987816200539cc1303092402b30a6dcb7 (diff) | |
| download | usermoji-2a078adee47316974d813bb4234d956cb15fdbb0.tar.xz | |
layers: Fix access violation in LVT
Was sending an out-of-scope memory reference to the display driver
in unique_objects::AllocateMemory.
Change-Id: I6b700445125acab040310682c96e7507d0fd91aa
Diffstat (limited to 'layers/unique_objects.cpp')
| -rw-r--r-- | layers/unique_objects.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/layers/unique_objects.cpp b/layers/unique_objects.cpp index b23f774b..1a79d771 100644 --- a/layers/unique_objects.cpp +++ b/layers/unique_objects.cpp @@ -335,11 +335,11 @@ VKAPI_ATTR VkResult VKAPI_CALL AllocateMemory(VkDevice device, const VkMemoryAll const VkAllocationCallbacks *pAllocator, VkDeviceMemory *pMemory) { const VkMemoryAllocateInfo *input_allocate_info = pAllocateInfo; std::unique_ptr<safe_VkMemoryAllocateInfo> safe_allocate_info; + std::unique_ptr<safe_VkDedicatedAllocationMemoryAllocateInfoNV> safe_dedicated_allocate_info; layer_data *device_data = get_my_data_ptr(get_dispatch_key(device), layer_data_map); if ((pAllocateInfo != nullptr) && ContainsExtStruct(pAllocateInfo, VK_STRUCTURE_TYPE_DEDICATED_ALLOCATION_MEMORY_ALLOCATE_INFO_NV)) { - std::unique_ptr<safe_VkDedicatedAllocationMemoryAllocateInfoNV> safe_dedicated_allocate_info; // Assuming there is only one extension struct of this type in the list for now safe_dedicated_allocate_info = std::unique_ptr<safe_VkDedicatedAllocationMemoryAllocateInfoNV>(new safe_VkDedicatedAllocationMemoryAllocateInfoNV); |
