diff options
| author | Tobin Ehlis <tobine@google.com> | 2016-10-11 18:46:21 -0600 |
|---|---|---|
| committer | Tobin Ehlis <tobine@google.com> | 2016-10-18 12:40:32 -0600 |
| commit | f00324d9aa4cbeb9e4673703a17184cc626593cf (patch) | |
| tree | 3d4960367e6bf520ff3f2d4e24d9c04faa2e8fd0 /layers/core_validation.cpp | |
| parent | 176ecbf1c8e766d662fdb4d990bd60ea3fcdba20 (diff) | |
| download | usermoji-f00324d9aa4cbeb9e4673703a17184cc626593cf.tar.xz | |
layers:Fix memory cleanup at DestroyImage time
Need to ClearMemoryObjectBindings() when an image is destroyed. Do
this even if mem_info is NULL which it will be for sparse bindings.
Diffstat (limited to 'layers/core_validation.cpp')
| -rw-r--r-- | layers/core_validation.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index 861d9abf..639c0b4b 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -5831,8 +5831,8 @@ static void PostCallRecordDestroyImage(layer_data *dev_data, VkImage image, IMAG auto mem_info = getMemObjInfo(dev_data, image_state->binding.mem); if (mem_info) { RemoveImageMemoryRange(obj_struct.handle, mem_info); - ClearMemoryObjectBinding(dev_data, obj_struct.handle, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT, mem_info->mem); } + ClearMemoryObjectBindings(dev_data, obj_struct.handle, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT); // Remove image from imageMap dev_data->imageMap.erase(image); |
