X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=src%2Fipc.c;h=031ee9ab5d78bea6369b740bdc84f760fb734c99;hb=db33da225842fe8c3be296b48aba6e9d1bbe0c0d;hp=a7b46f62c978c69e96025bd7f1588649e4ab72dc;hpb=c3d0957efd46eaf86e711215f1ca8743157ab2da;p=i3%2Fi3 diff --git a/src/ipc.c b/src/ipc.c index a7b46f62..031ee9ab 100644 --- a/src/ipc.c +++ b/src/ipc.c @@ -59,8 +59,10 @@ static bool mkdirp(const char *path) { copy[strlen(copy)-1] = '\0'; char *sep = strrchr(copy, '/'); - if (sep == NULL) + if (sep == NULL) { + FREE(copy); return false; + } *sep = '\0'; bool result = false; if (mkdirp(copy)) @@ -282,7 +284,7 @@ void dump_node(yajl_gen gen, struct Con *con, bool inplace_restart) { ystr("focus"); y(array_open); - TAILQ_FOREACH(node, &(con->focus_head), nodes) { + TAILQ_FOREACH(node, &(con->focus_head), focused) { y(integer, (long int)node); } y(array_close);