summaryrefslogtreecommitdiff
path: root/symbols.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2022-12-10 14:10:32 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2022-12-11 15:36:06 -0800
commit2ac6a7f029d8855fbb4e8024aab0511727ac3a67 (patch)
treee358d01442ad5e619d9f328a79c9309cf6ff6672 /symbols.c
parent8d85bd1e2f9473958b235caf7af9913b518f73dd (diff)
downloadxorg-app-xkbcomp-2ac6a7f029d8855fbb4e8024aab0511727ac3a67.tar.gz
Replace uFree() with direct free() calls
All these wrappers did was mess with types and add a test for NULL pointers that isn't needed in C89 and later. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Diffstat (limited to 'symbols.c')
-rw-r--r--symbols.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/symbols.c b/symbols.c
index 310ad07..75adbaf 100644
--- a/symbols.c
+++ b/symbols.c
@@ -124,10 +124,10 @@ FreeKeyInfo(KeyInfo * info)
info->numLevels[i] = 0;
info->types[i] = None;
if (info->syms[i] != NULL)
- uFree(info->syms[i]);
+ free(info->syms[i]);
info->syms[i] = NULL;
if (info->acts[i] != NULL)
- uFree(info->acts[i]);
+ free(info->acts[i]);
info->acts[i] = NULL;
}
info->dfltType = None;
@@ -257,7 +257,7 @@ static void
FreeSymbolsInfo(SymbolsInfo * info)
{
if (info->name)
- uFree(info->name);
+ free(info->name);
info->name = NULL;
if (info->keys)
{
@@ -265,7 +265,7 @@ FreeSymbolsInfo(SymbolsInfo * info)
{
FreeKeyInfo(&info->keys[i]);
}
- uFree(info->keys);
+ free(info->keys);
info->keys = NULL;
}
if (info->modMap)
@@ -444,13 +444,13 @@ MergeKeyGroups(SymbolsInfo * info,
}
}
if ((into->syms[group] != NULL) && (resultSyms != into->syms[group]))
- uFree(into->syms[group]);
+ free(into->syms[group]);
if ((from->syms[group] != NULL) && (resultSyms != from->syms[group]))
- uFree(from->syms[group]);
+ free(from->syms[group]);
if ((into->acts[group] != NULL) && (resultActs != into->acts[group]))
- uFree(into->acts[group]);
+ free(into->acts[group]);
if ((from->acts[group] != NULL) && (resultActs != from->acts[group]))
- uFree(from->acts[group]);
+ free(from->acts[group]);
into->numLevels[group] = resultWidth;
into->syms[group] = resultSyms;
from->syms[group] = NULL;
@@ -476,9 +476,9 @@ MergeKeys(SymbolsInfo * info, KeyInfo * into, KeyInfo * from)
if (into->numLevels[i] != 0)
{
if (into->syms[i])
- uFree(into->syms[i]);
+ free(into->syms[i]);
if (into->acts[i])
- uFree(into->acts[i]);
+ free(into->acts[i]);
}
}
*into = *from;
@@ -740,7 +740,7 @@ MergeIncludedSymbols(SymbolsInfo * into, SymbolsInfo * from,
if (!AddModMapEntry(into, mm))
into->errorCount++;
next = (ModMapEntry *) mm->defs.next;
- uFree(mm);
+ free(mm);
}
from->modMap = NULL;
}
@@ -788,7 +788,7 @@ HandleIncludeSymbols(IncludeStmt * stmt,
if (stmt->stmt != NULL)
{
if (included.name != NULL)
- uFree(included.name);
+ free(included.name);
included.name = stmt->stmt;
stmt->stmt = NULL;
}
@@ -1534,10 +1534,10 @@ SetExplicitGroup(SymbolsInfo * info, KeyInfo * key)
{
key->numLevels[i] = 0;
if (key->syms[i] != NULL)
- uFree(key->syms[i]);
+ free(key->syms[i]);
key->syms[i] = (KeySym *) NULL;
if (key->acts[i] != NULL)
- uFree(key->acts[i]);
+ free(key->acts[i]);
key->acts[i] = (XkbAction *) NULL;
key->types[i] = (Atom) 0;
}
@@ -1924,10 +1924,10 @@ PrepareKeyDef(KeyInfo * key)
{
key->numLevels[i] = 0;
if (key->syms[i] != NULL)
- uFree(key->syms[i]);
+ free(key->syms[i]);
key->syms[i] = (KeySym *) NULL;
if (key->acts[i] != NULL)
- uFree(key->acts[i]);
+ free(key->acts[i]);
key->acts[i] = (XkbAction *) NULL;
key->types[i] = (Atom) 0;
}