aboutsummaryrefslogtreecommitdiff
path: root/nx-X11
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2019-07-23 20:10:43 +0200
committerUlrich Sibiller <uli42@gmx.de>2019-08-06 21:57:32 +0200
commit4421f787ddf102889ee65cd310cc50369540dbc8 (patch)
treebc55cf10e0be635057b8edc46bf44c88481db52c /nx-X11
parent7d25771da3eed13a2779792fa53fdac01d567bd4 (diff)
downloadnx-libs-4421f787ddf102889ee65cd310cc50369540dbc8.tar.gz
nx-libs-4421f787ddf102889ee65cd310cc50369540dbc8.tar.bz2
nx-libs-4421f787ddf102889ee65cd310cc50369540dbc8.zip
Atoms.c: use SAFE_XFree and SAFE_free macros
Diffstat (limited to 'nx-X11')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Atoms.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c
index c36c38e2f..2ee67b9bb 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c
@@ -43,6 +43,7 @@
#include "Screen.h"
#include "Options.h"
#include "Agent.h"
+#include "Utils.h"
/*
* Set here the required log level.
@@ -53,11 +54,6 @@
#undef TEST
#undef DEBUG
-#ifdef DEBUG
-/* for validateString() */
-#include "Utils.h"
-#endif
-
/*
* These values should be moved in
* the option repository.
@@ -482,8 +478,8 @@ static int nxagentInitAtomMap(char **atomNameList, int count, Atom *atomsRet)
fprintf(stderr, "nxagentInitAtomMap: WARNING! XInternAtoms request failed.\n");
#endif
- free(atom_list);
- free(name_list);
+ SAFE_free(atom_list);
+ SAFE_free(name_list);
return 0;
}
@@ -523,8 +519,8 @@ static int nxagentInitAtomMap(char **atomNameList, int count, Atom *atomsRet)
}
}
- free(atom_list);
- free(name_list);
+ SAFE_free(atom_list);
+ SAFE_free(name_list);
nxagentPrintAtomMapInfo("nxagentInitAtomMap: Exiting");
@@ -794,7 +790,7 @@ Atom nxagentRemoteToLocalAtom(Atom remote)
#ifdef TEST
fprintf(stderr, "%s: remote [%d (%s)] -> local [%d]\n", __func__, remote, string, local);
#endif
- XFree(string);
+ SAFE_XFree(string);
return local;
}