From: Axel Wagner Date: Tue, 25 Jan 2011 23:34:15 +0000 (+0100) Subject: Bugfix: free() workspace-names seperately (thx dothebart) X-Git-Tag: 4.0.1~7^2~3^2~36 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=da1b65dd867608ea08a7efacfb19ec83814cd744;p=i3%2Fi3 Bugfix: free() workspace-names seperately (thx dothebart) --- diff --git a/i3bar/src/workspaces.c b/i3bar/src/workspaces.c index a28ed2be..0393071e 100644 --- a/i3bar/src/workspaces.c +++ b/i3bar/src/workspaces.c @@ -258,8 +258,14 @@ void free_workspaces() { if (outputs == NULL) { return; } + i3_ws *ws_walk; + SLIST_FOREACH(outputs_walk, outputs, slist) { if (outputs_walk->workspaces != NULL && !TAILQ_EMPTY(outputs_walk->workspaces)) { + TAILQ_FOREACH(ws_walk, outputs_walk->workspaces, tailq) { + FREE(ws_walk->name); + FREE(ws_walk->ucs2_name); + } FREE_TAILQ(outputs_walk->workspaces, i3_ws); } }