aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs
diff options
context:
space:
mode:
Diffstat (limited to 'nx-X11/programs')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Keyboard.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c
index 8ae64ee00..e77e44465 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c
@@ -1904,10 +1904,12 @@ void nxagentKeycodeConversionSetup(void)
FILE *keyboard_file;
if (!keyboard_file_path)
{
- FatalError("nxagentKeycodeConversionSetup: malloc failed.");
+ free(sessionpath);
+ FatalError("malloc for keyboard file path failed.");
}
strcpy(keyboard_file_path, sessionpath);
strcat(keyboard_file_path, "/keyboard");
+ free(sessionpath);
if ((keyboard_file = fopen(keyboard_file_path, "w"))) {
if (drules)
fprintf(keyboard_file, "rules=\"%s\"\n", drules[0] == '\0' ? "," : drules);