From fd32868590c7cbc5c6c2b3d59ff66694de3864b8 Mon Sep 17 00:00:00 2001 From: Jan Ziak <0xe2.0x9a.0x9b@gmail.com> Date: Sat, 30 Jul 2016 02:31:10 +0200 Subject: [PATCH] loader: fix memory leak in loader_dri3_open Found via "valgrind --leak-check=full glxgears". Signed-off-by: Jan Ziak (http://atom-symbol.net) <0xe2.0x9a.0x9b@gmail.com> Acked-by: Boyan Ding Cc: "12.0 11.2" Reviewed-by: Eric Anholt --- src/loader/loader_dri3_helper.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/loader/loader_dri3_helper.c b/src/loader/loader_dri3_helper.c index 896f2252f36..67d0c2c2f3a 100644 --- a/src/loader/loader_dri3_helper.c +++ b/src/loader/loader_dri3_helper.c @@ -785,6 +785,7 @@ loader_dri3_open(xcb_connection_t *conn, } fd = xcb_dri3_open_reply_fds(conn, reply)[0]; + free(reply); fcntl(fd, F_SETFD, fcntl(fd, F_GETFD) | FD_CLOEXEC); return fd; -- 2.30.2