diff options
author | Leandro Pereira <leandro@hardinfo.org> | 2010-01-03 22:38:49 -0200 |
---|---|---|
committer | Leandro Pereira <leandro@hardinfo.org> | 2010-01-03 22:38:49 -0200 |
commit | 1e1a647f6fb643163b34604d35e15a1341be007e (patch) | |
tree | c0d8b6a66d89ddfbdbceed6b03d252442a352663 /hardinfo2 | |
parent | 7d8f97e3e07f65b90fed9a10de78cdb285acc455 (diff) |
Reorganize module_unload_all() so that all references to a GModule's address space are cleared out before they're actually unloaded.
Diffstat (limited to 'hardinfo2')
-rw-r--r-- | hardinfo2/util.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/hardinfo2/util.c b/hardinfo2/util.c index 131f667e..01106c9d 100644 --- a/hardinfo2/util.c +++ b/hardinfo2/util.c @@ -628,21 +628,20 @@ void module_unload_all(void) shell = shell_get_main_shell(); + sync_manager_clear_entries(); + shell_clear_timeouts(shell); + shell_clear_tree_models(shell); + shell_clear_field_updates(); + shell_set_title(shell, NULL); + for (module = shell->tree->modules; module; module = module->next) { module_unload((ShellModule *)module->data); } - + for (merge_id = shell->merge_ids; merge_id; merge_id = merge_id->next) { gtk_ui_manager_remove_ui(shell->ui_manager, GPOINTER_TO_INT(merge_id->data)); } - - sync_manager_clear_entries(); - shell_clear_timeouts(shell); - shell_clear_tree_models(shell); - shell_clear_field_updates(); - shell_set_title(shell, NULL); - g_slist_free(shell->tree->modules); g_slist_free(shell->merge_ids); |