summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIago Toral Quiroga <[email protected]>2018-02-05 09:49:54 +0100
committerEmil Velikov <[email protected]>2018-02-28 20:14:24 +0000
commit758355b34c073dd8d4f9ee3558f899a0747b3577 (patch)
tree08c47764ebaa2cff22fc9074c845294dda09fb38
parent7adc454c94b1241106c0fd7147c04686352a53c2 (diff)
anv/device: initialize the list of enabled extensions properly
The loop goes through the list of enabled extensions marking them as enabled in the list, but this relies on every other extension being initialized to false by default. This bug would make us, for example, advertise certain device extension entry points as available even when the corresponding extensions had not been enabled. Reviewed-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]> Fixes: abc62282b5c "anv: Add a per-device table of enabled extensions" Cc: "18.0" <[email protected]> (cherry picked from commit a5053ba27ed76f666e315de7150433c5aaaaf2c3)
-rw-r--r--src/intel/vulkan/anv_device.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c
index 0cba17aa169..86c1bdc1d51 100644
--- a/src/intel/vulkan/anv_device.c
+++ b/src/intel/vulkan/anv_device.c
@@ -1331,7 +1331,7 @@ VkResult anv_CreateDevice(
assert(pCreateInfo->sType == VK_STRUCTURE_TYPE_DEVICE_CREATE_INFO);
- struct anv_device_extension_table enabled_extensions;
+ struct anv_device_extension_table enabled_extensions = { };
for (uint32_t i = 0; i < pCreateInfo->enabledExtensionCount; i++) {
int idx;
for (idx = 0; idx < ANV_DEVICE_EXTENSION_COUNT; idx++) {