mirror of
https://github.com/Interlisp/maiko.git
synced 2026-02-15 04:06:19 +00:00
XFree(mapping) was called *before* mapping was referenced in DEBUG conditional code. (#486)
This is only a potential issue in DEBUG build. A problem hasn't occurred, that I know of, but it seemed best just to be safe. Moved the DEBUG code to precede the XFree(mapping) call. (Equivalent to moving the XFree down.)
This commit is contained in:
@@ -375,8 +375,6 @@ static u_char *make_X_keymap(void) {
|
||||
table[xcode - 7] = code;
|
||||
}
|
||||
|
||||
XFree(mapping); /* No locking required? */
|
||||
|
||||
#ifdef DEBUG
|
||||
printf("\n\n\tXGetKeyboardMapping table\n\n");
|
||||
for (i = 0; i < codecount * symspercode; i += symspercode) {
|
||||
@@ -394,6 +392,8 @@ static u_char *make_X_keymap(void) {
|
||||
}
|
||||
#endif /* DEBUG */
|
||||
|
||||
XFree(mapping); /* No locking required? */
|
||||
|
||||
return (table);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user