Fix undefined C++ behavior (resulting in errors when doing runtime memory checks),
where a temporary object returned by getInputAspects() method is used by a reference
to a member after the temporary is destructed.
It seems getInputAspects should just return reference.
Affects: dEQP-VK.renderpass.*.input*
Component: Vulkan
VK-GL-CTS Issue: 1033
Change-Id: I71edabed71ea63f46cdbc45c966d57cd020565ab
const vector<Attachment>& getAttachments (void) const { return m_attachments; }
const vector<Subpass>& getSubpasses (void) const { return m_subpasses; }
const vector<SubpassDependency>& getDependencies (void) const { return m_dependencies; }
- const vector<VkInputAttachmentAspectReferenceKHR> getInputAspects (void) const { return m_inputAspects; }
+ const vector<VkInputAttachmentAspectReferenceKHR>& getInputAspects (void) const { return m_inputAspects; }
private:
const vector<Attachment> m_attachments;