KhronosGroup / VK-GL-CTS

Khronos Vulkan, OpenGL, and OpenGL ES Conformance Tests
https://www.khronos.org/
Apache License 2.0
526 stars 295 forks source link

Out-of-bounds read in populateBufferWithCopy #417 #481

Open sumcai opened 3 months ago

sumcai commented 3 months ago

PopulateBufferWithCopy actually calls deMemcpy, use buffer access range size when copy data from blob.

void populateBufferWithCopy(void *buffer, VkDeviceSize size, const void *const blob)
{
    deMemcpy(buffer, blob, static_cast<size_t>(size));
}