[Mesa-dev] [PATCH 1/1] wayland-drm: Remove an unnecessary close()
Satyeshwar Singh
satyeshwar.singh at intel.com
Wed Sep 17 09:51:51 PDT 2014
The code in drm_create_prime_buffer() is closing the fd handle but
it was also being closed by the callers of this function in
platform_wayland.c. To make the code look the same as other
drm_create_*_buffers in wayland-drm, removing the close() from here
and leaving the responsibility of closing the fd to the callers.
---
src/egl/wayland/wayland-drm/wayland-drm.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/src/egl/wayland/wayland-drm/wayland-drm.c b/src/egl/wayland/wayland-drm/wayland-drm.c
index e9c6e0a..a409523 100644
--- a/src/egl/wayland/wayland-drm/wayland-drm.c
+++ b/src/egl/wayland/wayland-drm/wayland-drm.c
@@ -180,7 +180,6 @@ drm_create_prime_buffer(struct wl_client *client,
{
create_buffer(client, resource, id, 0, fd, width, height, format,
offset0, stride0, offset1, stride1, offset2, stride2);
- close(fd);
}
static void
--
1.7.11.7
More information about the mesa-dev
mailing list