From 0ef302638f2883789a3b39c2b6cfd20814efa0bb Mon Sep 17 00:00:00 2001 From: Grazvydas Ignotas Date: Tue, 2 May 2017 20:11:06 +0300 Subject: [PATCH] anv: don't leak DRM devices After successful drmGetDevices2() call, drmFreeDevices() needs to be called. Fixes: b1fb6e8d "anv: do not open random render node(s)" Signed-off-by: Grazvydas Ignotas Reviewed-by: Bas Nieuwenhuizen # radv version --- src/intel/vulkan/anv_device.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c index a64eae1ac99..35e40301a31 100644 --- a/src/intel/vulkan/anv_device.c +++ b/src/intel/vulkan/anv_device.c @@ -526,6 +526,7 @@ anv_enumerate_devices(struct anv_instance *instance) break; } } + drmFreeDevices(devices, max_devices); if (result == VK_SUCCESS) instance->physicalDeviceCount = 1; -- 2.30.2