home
·
contact
·
privacy
projects
/
plomrogue
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Made keybindings array into linked list; on the way rewrote / improved great parts...
[plomrogue]
/
src
/
rexit.c
diff --git
a/src/rexit.c
b/src/rexit.c
index e39a9feaa658fae15e8e9a40568e0b8994546d32..01c572775b611eb1ca5d6e0d5a6b6501131e54ee 100644
(file)
--- a/
src/rexit.c
+++ b/
src/rexit.c
@@
-33,12
+33,17
@@
static void cleanup(struct World * world)
}
if (cleanup_flags & CLEANUP_KEYBINDINGS)
{
}
if (cleanup_flags & CLEANUP_KEYBINDINGS)
{
- uint16_t key;
- for (key = 0; key <= world->keyswindata->max; key++)
+/*
+ uint16_t i = 0;
+ struct KeyBinding * kb_p = world->keybindings;
+ while (1)
{
{
+ free(kb_p);
free(world->keybindings[key].name);
}
free(world->keybindings);
free(world->keybindings[key].name);
}
free(world->keybindings);
+*/
+ free_keybindings(world->keybindings);
free(world->keyswindata);
}
if (cleanup_flags & CLEANUP_LOG)
free(world->keyswindata);
}
if (cleanup_flags & CLEANUP_LOG)