Introduce a xreallocarray and convert a few xcalloc instances that do

not require zero'ing.
This commit is contained in:
okan
2015-03-28 23:12:47 +00:00
parent 0bbe0ad98c
commit a4a414b68b
4 changed files with 18 additions and 5 deletions

View File

@ -91,7 +91,7 @@ group_restack(struct group_ctx *gc)
if (cc->stackingorder > highstack)
highstack = cc->stackingorder;
}
winlist = xcalloc((highstack + 1), sizeof(*winlist));
winlist = xreallocarray(NULL, (highstack + 1), sizeof(*winlist));
/* Invert the stacking order for XRestackWindows(). */
TAILQ_FOREACH(cc, &gc->clientq, group_entry) {