summaryrefslogtreecommitdiff
path: root/layers/core_validation.cpp
diff options
context:
space:
mode:
authorTobin Ehlis <tobine@google.com>2016-09-22 07:30:05 -0600
committerTobin Ehlis <tobine@google.com>2016-09-22 07:30:05 -0600
commit12d5600c2f9e32343016fd944432ba95df370797 (patch)
tree3b3f66f058a603a65f7d752e3e3ac98caae6e41a /layers/core_validation.cpp
parent333b2211e317f6fefe2709a8514b18fcf3515839 (diff)
layers: A few minor clean-ups from code review
Better use of auto and killing some unneeded code.
Diffstat (limited to 'layers/core_validation.cpp')
-rw-r--r--layers/core_validation.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp
index 2d1214fb..df0e180a 100644
--- a/layers/core_validation.cpp
+++ b/layers/core_validation.cpp
@@ -3730,7 +3730,7 @@ template <class OBJECT, class LAYOUT> void SetLayout(OBJECT *pObject, VkImage im
void SetLayout(const layer_data *dev_data, GLOBAL_CB_NODE *pCB, VkImageView imageView, const VkImageLayout &layout) {
auto view_state = getImageViewState(dev_data, imageView);
assert(view_state);
- const VkImage &image = view_state->create_info.image;
+ auto image = view_state->create_info.image;
const VkImageSubresourceRange &subRange = view_state->create_info.subresourceRange;
// TODO: Do not iterate over every possibility - consolidate where possible
for (uint32_t j = 0; j < subRange.levelCount; j++) {
@@ -9213,7 +9213,7 @@ static bool ValidateFramebufferCreateInfo(layer_data *dev_data, const VkFramebuf
const VkImageView *image_views = pCreateInfo->pAttachments;
for (uint32_t i = 0; i < pCreateInfo->attachmentCount; ++i) {
auto view_state = getImageViewState(dev_data, image_views[i]);
- auto ivci = view_state->create_info;
+ auto &ivci = view_state->create_info;
if (ivci.format != rpci->pAttachments[i].format) {
skip_call |= log_msg(
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_RENDER_PASS_EXT,