[PATCH xserver 02/15] xwayland: don't close() fds we don't own
Emil Velikov
emil.l.velikov at gmail.com
Mon Apr 2 15:41:13 UTC 2018
From: Emil Velikov <emil.velikov at collabora.com>
The glamor_pixmap_from_fds error path erroneously closes the fds.
We don't own them, plus the caller closes them after the function in
called.
Fixes: cef12efc15c ("glamor: Implement GetSupportedModifiers")
Cc: Louis-Francis Ratté-Boulianne <lfrb at collabora.com>
Cc: Daniel Stone <daniels at collabora.com>
Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
---
hw/xwayland/xwayland-glamor.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/hw/xwayland/xwayland-glamor.c b/hw/xwayland/xwayland-glamor.c
index 7f64483bf..6ba716263 100644
--- a/hw/xwayland/xwayland-glamor.c
+++ b/hw/xwayland/xwayland-glamor.c
@@ -704,8 +704,6 @@ glamor_pixmap_from_fds(ScreenPtr screen,
return pixmap;
error:
- for (i = 0; i < num_fds; i++)
- close(fds[i]);
return NULL;
}
--
2.16.0
More information about the xorg-devel
mailing list