[RFC wayland 06/12] connection: close pending incoming FDs on shutdown

David Herrmann dh.herrmann at googlemail.com
Thu Oct 11 14:37:47 PDT 2012


Same problem as with outgoing FDs. We need to close these on shutdown,
otherwise we leak open file descriptors.

Signed-off-by: David Herrmann <dh.herrmann at googlemail.com>
---
 src/connection.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/connection.c b/src/connection.c
index 355fd54..8264470 100644
--- a/src/connection.c
+++ b/src/connection.c
@@ -190,6 +190,7 @@ void
 wl_connection_destroy(struct wl_connection *connection)
 {
 	close_fds(&connection->fds_out, -1);
+	close_fds(&connection->fds_in, -1);
 	close(connection->fd);
 	free(connection);
 }
-- 
1.7.12.2



More information about the wayland-devel mailing list