mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-27 21:16:22 +00:00
Check for win callback hash before removing
This commit is contained in:
@@ -159,13 +159,15 @@ callbacks_remove(const char *const plugin_name)
|
|||||||
g_hash_table_remove(p_timed_functions, plugin_name);
|
g_hash_table_remove(p_timed_functions, plugin_name);
|
||||||
|
|
||||||
GHashTable *tag_to_win_cb_hash = g_hash_table_lookup(p_window_callbacks, plugin_name);
|
GHashTable *tag_to_win_cb_hash = g_hash_table_lookup(p_window_callbacks, plugin_name);
|
||||||
GList *tags = g_hash_table_get_keys(tag_to_win_cb_hash);
|
if (tag_to_win_cb_hash) {
|
||||||
GList *curr = tags;
|
GList *tags = g_hash_table_get_keys(tag_to_win_cb_hash);
|
||||||
while (curr) {
|
GList *curr = tags;
|
||||||
wins_close_plugin(curr->data);
|
while (curr) {
|
||||||
curr = g_list_next(curr);
|
wins_close_plugin(curr->data);
|
||||||
|
curr = g_list_next(curr);
|
||||||
|
}
|
||||||
|
g_list_free(tags);
|
||||||
}
|
}
|
||||||
g_list_free(tags);
|
|
||||||
|
|
||||||
g_hash_table_remove(p_window_callbacks, plugin_name);
|
g_hash_table_remove(p_window_callbacks, plugin_name);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user