From: Charles Johnston Date: Thu, 7 Jan 2021 15:00:48 +0000 (-0500) Subject: Fix heap read out of bounds in RenderPass tests. X-Git-Tag: upstream/1.3.5~320^2~26^2^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b98be4b8af66a7e8d83abdaec9e13f6f7519bacf;p=platform%2Fupstream%2FVK-GL-CTS.git Fix heap read out of bounds in RenderPass tests. Pass the correct size of the buffer to uploadBufferData. Affected tests: dEQP-VK.renderpass*.attachment_allocation.* dEQP-VK.renderpass*.suballocation.* Components: Vulkan VK-GL-CTS issue: 2708 Change-Id: Ib498be09f1c8437e8080c5b5f3a12d8b7a25a262 --- diff --git a/external/vulkancts/modules/vulkan/renderpass/vktRenderPassTests.cpp b/external/vulkancts/modules/vulkan/renderpass/vktRenderPassTests.cpp index 39f5a12..d8d61be 100644 --- a/external/vulkancts/modules/vulkan/renderpass/vktRenderPassTests.cpp +++ b/external/vulkancts/modules/vulkan/renderpass/vktRenderPassTests.cpp @@ -2121,7 +2121,7 @@ public: bindBufferMemory(vk, device, *m_vertexBuffer, m_vertexBufferMemory->getMemory(), m_vertexBufferMemory->getOffset()); - uploadBufferData(vk, device, *m_vertexBufferMemory, static_cast(vertexBufferSize), renderQuad.getVertexPointer(), properties.limits.nonCoherentAtomSize); + uploadBufferData(vk, device, *m_vertexBufferMemory, renderQuad.getVertexDataSize(), renderQuad.getVertexPointer(), properties.limits.nonCoherentAtomSize); if (renderInfo.getInputAttachmentCount() > 0) {