summaryrefslogtreecommitdiff
path: root/symbols.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2022-12-10 13:44:17 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2022-12-11 14:35:34 -0800
commit75af06f5f8ffc41fabd100253aad222cb4ab8662 (patch)
treecbb2735d3981ae92b272b761eb966e9c910ecea1 /symbols.c
parent265ea3a77418df2744575f1168f89a33f01e72d4 (diff)
downloadxorg-app-xkbcomp-75af06f5f8ffc41fabd100253aad222cb4ab8662.tar.gz
Replace uCalloc() and uTypedCalloc() with direct calloc() calls
All these wrappers did was mess with types. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Diffstat (limited to 'symbols.c')
-rw-r--r--symbols.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/symbols.c b/symbols.c
index ba5af49..b026ce7 100644
--- a/symbols.c
+++ b/symbols.c
@@ -166,7 +166,7 @@ CopyKeyInfo(KeyInfo * old, KeyInfo * new, Bool clearOld)
int width = new->numLevels[i];
if (old->syms[i] != NULL)
{
- new->syms[i] = uTypedCalloc(width, KeySym);
+ new->syms[i] = calloc(width, sizeof(KeySym));
if (!new->syms[i])
{
new->syms[i] = NULL;
@@ -178,7 +178,7 @@ CopyKeyInfo(KeyInfo * old, KeyInfo * new, Bool clearOld)
}
if (old->acts[i] != NULL)
{
- new->acts[i] = uTypedCalloc(width, XkbAction);
+ new->acts[i] = calloc(width, sizeof(XkbAction));
if (!new->acts[i])
{
new->acts[i] = NULL;
@@ -242,7 +242,7 @@ InitSymbolsInfo(SymbolsInfo * info, XkbDescPtr xkb)
info->groupInfo = 0;
info->szKeys = SYMBOLS_INIT_SIZE;
info->nKeys = 0;
- info->keys = uTypedCalloc(SYMBOLS_INIT_SIZE, KeyInfo);
+ info->keys = calloc(SYMBOLS_INIT_SIZE, sizeof(KeyInfo));
info->modMap = NULL;
for (int i = 0; i < XkbNumKbdGroups; i++)
info->groupNames[i] = None;
@@ -343,7 +343,7 @@ MergeKeyGroups(SymbolsInfo * info,
}
if (resultSyms == NULL)
{
- resultSyms = uTypedCalloc(resultWidth, KeySym);
+ resultSyms = calloc(resultWidth, sizeof(KeySym));
if (!resultSyms)
{
WSGO("Could not allocate symbols for group merge\n");
@@ -354,7 +354,7 @@ MergeKeyGroups(SymbolsInfo * info,
}
if ((resultActs == NULL) && (into->acts[group] || from->acts[group]))
{
- resultActs = uTypedCalloc(resultWidth, XkbAction);
+ resultActs = calloc(resultWidth, sizeof(XkbAction));
if (!resultActs)
{
WSGO("Could not allocate actions for group merge\n");
@@ -1869,7 +1869,7 @@ PrepareKeyDef(KeyInfo * key)
}
if ((key->actsDefined & 1) && key->acts[0])
{
- key->acts[i] = uTypedCalloc(width, XkbAction);
+ key->acts[i] = calloc(width, sizeof(XkbAction));
if (key->acts[i] == NULL)
continue;
memcpy((void *) key->acts[i], (void *) key->acts[0],
@@ -1878,7 +1878,7 @@ PrepareKeyDef(KeyInfo * key)
}
if ((key->symsDefined & 1) && key->syms[0])
{
- key->syms[i] = uTypedCalloc(width, KeySym);
+ key->syms[i] = calloc(width, sizeof(KeySym));
if (key->syms[i] == NULL)
continue;
memcpy((void *) key->syms[i], (void *) key->syms[0],