]> git.sur5r.net Git - i3/i3/commitdiff
fix memleak: free X state structure
authorMichael Stapelberg <michael@stapelberg.de>
Tue, 4 Jan 2011 21:39:24 +0000 (22:39 +0100)
committerMichael Stapelberg <michael@stapelberg.de>
Tue, 4 Jan 2011 21:39:24 +0000 (22:39 +0100)
src/x.c

diff --git a/src/x.c b/src/x.c
index fa0030200e3acf95e8028bfa2a71d51cdd074892..bcdb07ca2241a42953babfb9891a1be93dc4146a 100644 (file)
--- a/src/x.c
+++ b/src/x.c
@@ -168,6 +168,8 @@ void x_con_kill(Con *con) {
     state = state_for_frame(con->frame);
     CIRCLEQ_REMOVE(&state_head, state, state);
     CIRCLEQ_REMOVE(&old_state_head, state, old_state);
+    FREE(state->name);
+    free(state);
 
     /* Invalidate focused_id to correctly focus new windows with the same ID */
     focused_id = XCB_NONE;