summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Hill <dhill@conformal.com>2014-06-15 16:00:26 -0400
committerDavid Hill <dhill@conformal.com>2014-06-15 16:00:26 -0400
commitc40c54d782851c2a0827e750646e40be11424bbc (patch)
treeeac05ff3318afe62b8bb8208eef4f07a498aad19
parent57f138c087b649b5bbbbcb75d455ef86f93297f4 (diff)
downloadirssi-c40c54d782851c2a0827e750646e40be11424bbc.zip
Replace deprecated g_tree_traverse with g_tree_foreach.
g_tree_foreach traverses the tree in sorted order, which is what irssi was already doing.
-rw-r--r--src/fe-common/core/keyboard.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/fe-common/core/keyboard.c b/src/fe-common/core/keyboard.c
index 94c6bfd7..8ccdd54e 100644
--- a/src/fe-common/core/keyboard.c
+++ b/src/fe-common/core/keyboard.c
@@ -360,8 +360,8 @@ static void key_states_rescan(void)
memset(used_keys, 0, sizeof(used_keys));
- g_tree_traverse(key_states, (GTraverseFunc) key_state_destroy,
- G_IN_ORDER, NULL);
+ g_tree_foreach(key_states, (GTraverseFunc) key_state_destroy,
+ NULL);
g_tree_destroy(key_states);
key_states = g_tree_new((GCompareFunc) strcmp);
@@ -870,8 +870,8 @@ void keyboard_deinit(void)
g_hash_table_destroy(keys);
g_hash_table_destroy(default_keys);
- g_tree_traverse(key_states, (GTraverseFunc) key_state_destroy,
- G_IN_ORDER, NULL);
+ g_tree_foreach(key_states, (GTraverseFunc) key_state_destroy,
+ NULL);
g_tree_destroy(key_states);
signal_remove("irssi init read settings", (SIGNAL_FUNC) read_keyboard_config);