]> git.sur5r.net Git - i3/i3/commitdiff
con_get_tree_representation: fix memory leak
authorMichael Stapelberg <michael@stapelberg.de>
Sat, 9 Jan 2016 13:05:05 +0000 (14:05 +0100)
committerMichael Stapelberg <michael@stapelberg.de>
Sat, 9 Jan 2016 16:06:58 +0000 (17:06 +0100)
src/con.c

index 51b2a3f606e5c9ad533d4fc9d27d16ba1e7e93d2..a3a2f2e332d322f54a4f1f68d15e6d93749a4cdb 100644 (file)
--- a/src/con.c
+++ b/src/con.c
@@ -1992,6 +1992,7 @@ char *con_get_tree_representation(Con *con) {
                   (TAILQ_FIRST(&(con->nodes_head)) == child ? "" : " "), child_txt);
         free(buf);
         buf = tmp_buf;
+        free(child_txt);
     }
 
     /* 3) close the brackets */