mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 12:28:22 +01:00
Fixed memory leak in wWorkspaceRename.
The function wtrimspace returns a wmalloced memory region, therefore it must be wfreed after usage again. Please take note that this also happens with every single line of menu files, which will get fixed in a separate commit.
This commit is contained in:
committed by
Carlos R. Mafra
parent
33328d997e
commit
4a4775f076
@@ -662,6 +662,7 @@ void wWorkspaceRename(WScreen * scr, int workspace, char *name)
|
||||
strncpy(buf, tmp, MAX_WORKSPACENAME_WIDTH);
|
||||
}
|
||||
buf[MAX_WORKSPACENAME_WIDTH] = 0;
|
||||
wfree(tmp);
|
||||
|
||||
/* update workspace */
|
||||
wfree(scr->workspaces[workspace]->name);
|
||||
|
||||
Reference in New Issue
Block a user