From: Emil Velikov <emil.veli...@collabora.com>

Seems like we've been leaking this for years. It became more obvious
with the recent refactoring.

Signed-off-by: Emil Velikov <emil.veli...@collabora.com>
---
 src/amdgpu_probe.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/amdgpu_probe.c b/src/amdgpu_probe.c
index 537d44c..588891c 100644
--- a/src/amdgpu_probe.c
+++ b/src/amdgpu_probe.c
@@ -243,6 +243,8 @@ amdgpu_probe(ScrnInfoPtr pScrn, int entity_num,
        return TRUE;
 
 error:
+       free(pPriv->ptr);
+       pPriv->ptr = NULL;
        return FALSE;
 }
 
-- 
2.16.0

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Reply via email to